Compare commits
7 Commits
master
...
dockerfile
Author | SHA1 | Date | |
---|---|---|---|
66efa5e17c | |||
d6c46b5c10 | |||
356071570a | |||
6ac78cbe89 | |||
b11d6f6d88 | |||
de8cf7aab8 | |||
fea176f7f3 |
60
.drone.yml
60
.drone.yml
@ -1,15 +1,6 @@
|
|||||||
---
|
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
name: linux-amd64
|
name: linux-amd64
|
||||||
|
|
||||||
trigger:
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
- tag
|
|
||||||
refs:
|
|
||||||
- refs/heads/master
|
|
||||||
- refs/tags/v*
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: build
|
- name: build
|
||||||
@ -22,19 +13,17 @@ steps:
|
|||||||
from_secret: docker_username
|
from_secret: docker_username
|
||||||
password:
|
password:
|
||||||
from_secret: docker_password
|
from_secret: docker_password
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- master
|
||||||
|
event:
|
||||||
|
- push
|
||||||
|
- tag
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
name: linux-arm
|
name: linux-arm
|
||||||
|
|
||||||
trigger:
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
- tag
|
|
||||||
refs:
|
|
||||||
- refs/heads/master
|
|
||||||
- refs/tags/v*
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: build
|
- name: build
|
||||||
@ -49,20 +38,18 @@ steps:
|
|||||||
from_secret: docker_password
|
from_secret: docker_password
|
||||||
build_args:
|
build_args:
|
||||||
- ARCH=arm
|
- ARCH=arm
|
||||||
- REPO=arm32v7
|
- REPO=arm32v6
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- master
|
||||||
|
event:
|
||||||
|
- push
|
||||||
|
- tag
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
name: linux-arm64
|
name: linux-arm64
|
||||||
|
|
||||||
trigger:
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
- tag
|
|
||||||
refs:
|
|
||||||
- refs/heads/master
|
|
||||||
- refs/tags/v*
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: build
|
- name: build
|
||||||
@ -78,6 +65,12 @@ steps:
|
|||||||
build_args:
|
build_args:
|
||||||
- ARCH=aarch64
|
- ARCH=aarch64
|
||||||
- REPO=arm64v8
|
- REPO=arm64v8
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- master
|
||||||
|
event:
|
||||||
|
- push
|
||||||
|
- tag
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
@ -88,14 +81,6 @@ depends_on:
|
|||||||
- linux-arm
|
- linux-arm
|
||||||
- linux-arm64
|
- linux-arm64
|
||||||
|
|
||||||
trigger:
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
- tag
|
|
||||||
refs:
|
|
||||||
- refs/heads/master
|
|
||||||
- refs/tags/v*
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: publish manifest
|
- name: publish manifest
|
||||||
image: plugins/manifest
|
image: plugins/manifest
|
||||||
@ -107,3 +92,10 @@ steps:
|
|||||||
from_secret: docker_username
|
from_secret: docker_username
|
||||||
password:
|
password:
|
||||||
from_secret: docker_password
|
from_secret: docker_password
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- master
|
||||||
|
event:
|
||||||
|
- push
|
||||||
|
- tag
|
||||||
|
|
||||||
|
13
Dockerfile
13
Dockerfile
@ -1,15 +1,14 @@
|
|||||||
ARG REPO=library
|
ARG REPO=library
|
||||||
|
|
||||||
FROM multiarch/qemu-user-static:4.2.0-2 as qemu-user-static
|
FROM multiarch/qemu-user-static:4.1.0-1 as qemu-user-static
|
||||||
# Make sure a dummy x86_64 file exists so that the copy command doesn't error
|
# Make sure a dummy x86_64 file exists so that the copy command doesn't error
|
||||||
# RUN touch /usr/bin/qemu-x86_64-fake
|
RUN touch /usr/bin/qemu-x86_64-fake
|
||||||
|
|
||||||
FROM ${REPO}/python:3.8-alpine
|
FROM ${REPO}/python:3-alpine
|
||||||
|
|
||||||
# Copy mutliarch file to run builds on x86_64
|
# Copy mutliarch file to run builds on x86_64
|
||||||
ARG ARCH=x86_64
|
ARG ARCH=x86_64
|
||||||
COPY --from=qemu-user-static /usr/bin/qemu-* /usr/bin/
|
COPY --from=qemu-user-static /usr/bin/qemu-${ARCH}-* /usr/bin/
|
||||||
# COPY --from=qemu-user-static /usr/bin/qemu-${ARCH}-* /usr/bin/
|
|
||||||
|
|
||||||
RUN mkdir -p /src
|
RUN mkdir -p /src
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
@ -17,9 +16,9 @@ WORKDIR /src
|
|||||||
# Get Cloudflare example script
|
# Get Cloudflare example script
|
||||||
ENV CF_VERSION=2.6.0
|
ENV CF_VERSION=2.6.0
|
||||||
ADD https://raw.githubusercontent.com/cloudflare/python-cloudflare/$CF_VERSION/examples/example_update_dynamic_dns.py ./update_ddns.py
|
ADD https://raw.githubusercontent.com/cloudflare/python-cloudflare/$CF_VERSION/examples/example_update_dynamic_dns.py ./update_ddns.py
|
||||||
RUN chmod +rx ./update_ddns.py
|
RUN chmod +x ./update_ddns.py
|
||||||
|
|
||||||
RUN python -m pip install --no-cache-dir cloudflare==$CF_VERSION
|
RUN pip install cloudflare==$CF_VERSION
|
||||||
|
|
||||||
ENV DOMAIN=""
|
ENV DOMAIN=""
|
||||||
|
|
||||||
|
2
Makefile
2
Makefile
@ -14,7 +14,7 @@ build:
|
|||||||
|
|
||||||
.PHONY: cross-build-arm
|
.PHONY: cross-build-arm
|
||||||
cross-build-arm:
|
cross-build-arm:
|
||||||
docker build --build-arg REPO=arm32v7 --build-arg ARCH=arm . -t ${DOCKER_TAG}-linux-arm
|
docker build --build-arg REPO=arm32v6 --build-arg ARCH=arm . -t ${DOCKER_TAG}-linux-arm
|
||||||
|
|
||||||
.PHONY: cross-build-arm64
|
.PHONY: cross-build-arm64
|
||||||
cross-build-arm64:
|
cross-build-arm64:
|
||||||
|
Loading…
Reference in New Issue
Block a user