Compare commits
12 Commits
Author | SHA1 | Date |
---|---|---|
IamTheFij | b5e99939fb | |
IamTheFij | 01dc2dd149 | |
IamTheFij | 4702310823 | |
IamTheFij | aef73188f2 | |
IamTheFij | 9a8445e6ec | |
IamTheFij | a752c67dad | |
IamTheFij | 2c9b26a283 | |
IamTheFij | ff2d50b6e8 | |
IamTheFij | d66c11cc00 | |
IamTheFij | fdb3c744b0 | |
IamTheFij | d9b20c4759 | |
IamTheFij | 2b41676824 |
60
.drone.yml
60
.drone.yml
|
@ -1,6 +1,15 @@
|
||||||
|
---
|
||||||
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
|
||||||
|
@ -13,17 +22,19 @@ 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
|
||||||
|
@ -38,18 +49,20 @@ steps:
|
||||||
from_secret: docker_password
|
from_secret: docker_password
|
||||||
build_args:
|
build_args:
|
||||||
- ARCH=arm
|
- ARCH=arm
|
||||||
- REPO=arm32v6
|
- REPO=arm32v7
|
||||||
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
|
||||||
|
@ -65,12 +78,6 @@ steps:
|
||||||
build_args:
|
build_args:
|
||||||
- ARCH=aarch64
|
- ARCH=aarch64
|
||||||
- REPO=arm64v8
|
- REPO=arm64v8
|
||||||
when:
|
|
||||||
branch:
|
|
||||||
- master
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
- tag
|
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
|
@ -81,6 +88,14 @@ 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
|
||||||
|
@ -92,10 +107,3 @@ 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,14 +1,15 @@
|
||||||
ARG REPO=library
|
ARG REPO=library
|
||||||
|
|
||||||
FROM multiarch/qemu-user-static:4.1.0-1 as qemu-user-static
|
FROM multiarch/qemu-user-static:4.2.0-2 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-alpine
|
FROM ${REPO}/python:3.8-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-${ARCH}-* /usr/bin/
|
COPY --from=qemu-user-static /usr/bin/qemu-* /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
|
||||||
|
@ -16,9 +17,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 +x ./update_ddns.py
|
RUN chmod +rx ./update_ddns.py
|
||||||
|
|
||||||
RUN pip install --no-cache-dir cloudflare==$CF_VERSION
|
RUN python -m pip install --no-cache-dir 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=arm32v6 --build-arg ARCH=arm . -t ${DOCKER_TAG}-linux-arm
|
docker build --build-arg REPO=arm32v7 --build-arg ARCH=arm . -t ${DOCKER_TAG}-linux-arm
|
||||||
|
|
||||||
.PHONY: cross-build-arm64
|
.PHONY: cross-build-arm64
|
||||||
cross-build-arm64:
|
cross-build-arm64:
|
||||||
|
|
|
@ -26,3 +26,9 @@ Or by providing a file mounted to the working directory in the image, `/src/.clo
|
||||||
Then run. To execute from this directory, you can use the convenient Make target.
|
Then run. To execute from this directory, you can use the convenient Make target.
|
||||||
|
|
||||||
make run
|
make run
|
||||||
|
|
||||||
|
## Source
|
||||||
|
|
||||||
|
Original source: https://git.iamthefij.com/iamthefij/docker-cloudflare-ddns
|
||||||
|
|
||||||
|
Github mirror: https://github.com/iamthefij/docker-cloudflare-ddns
|
Loading…
Reference in New Issue