File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ .github
2+ README.md
Original file line number Diff line number Diff line change 1+ name : Build
2+
3+ on :
4+ release :
5+ types : [published]
6+ push :
7+ tags :
8+ - ' *'
9+ schedule :
10+ - cron : ' 30 5 * * *'
11+
12+ env :
13+ IMAGE_TAG : ${{ github.event.release.tag_name }}
14+
15+ jobs :
16+ build-and-push-image :
17+ runs-on : ubuntu-latest
18+ steps :
19+ -
20+ name : Checkout
21+ uses : actions/checkout@v3
22+ -
23+ name : Set up QEMU
24+ uses : docker/setup-qemu-action@v2
25+ -
26+ name : Set up Docker Buildx
27+ uses : docker/setup-buildx-action@v2
28+ -
29+ name : Docker meta
30+ id : meta
31+ uses : docker/metadata-action@v4
32+ with :
33+ images : skyloud/rclone
34+ -
35+ name : Login to DockerHub
36+ uses : docker/login-action@v2
37+ with :
38+ username : ${{ secrets.DOCKER_HUB_USERNAME }}
39+ password : ${{ secrets.DOCKER_HUB_TOKEN }}
40+ -
41+ name : Build and push
42+ uses : docker/build-push-action@v3
43+ id : docker_build
44+ with :
45+ context : .
46+ platforms : linux/amd64,linux/arm64
47+ push : true
48+ tags : ${{ steps.meta.outputs.tags }}
49+ labels : ${{ steps.meta.outputs.labels }}
50+ -
51+ name : Image digest
52+ run : echo ${{ steps.docker_build.outputs.digest }}
Original file line number Diff line number Diff line change 1+ FROM rclone/rclone:latest
2+
3+ RUN apk add --no-cache curl
4+
5+ COPY --chmod=0755 ./entrypoint.sh /entrypoint.sh
6+
7+ ENTRYPOINT ["/entrypoint.sh" ]
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ set -e
4+
5+ rclone " $@ "
6+
7+ if [ -z " $HEARTBEAT_URL " ]; then
8+ echo " HEARTBEAT_URL is empty"
9+ exit 1
10+ fi
11+
12+ curl -sSL " $HEARTBEAT_URL "
You can’t perform that action at this time.
0 commit comments