mirror of
https://github.com/acmesh-official/acme.sh.git
synced 2025-05-05 23:17:41 +00:00
docker: for better maintenance
This commit is contained in:
parent
5b8d7a3f29
commit
5c4d1ec035
5
.github/workflows/dockerhub.yml
vendored
5
.github/workflows/dockerhub.yml
vendored
@ -8,10 +8,9 @@ on:
|
|||||||
- '*'
|
- '*'
|
||||||
paths:
|
paths:
|
||||||
- '**.sh'
|
- '**.sh'
|
||||||
- "Dockerfile"
|
- "docker/**"
|
||||||
- '.github/workflows/dockerhub.yml'
|
- '.github/workflows/dockerhub.yml'
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
CheckToken:
|
CheckToken:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -30,7 +29,7 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
- name: Check the value
|
- name: Check the value
|
||||||
run: echo ${{ steps.step_one.outputs.hasToken }}
|
run: echo ${{ steps.step_one.outputs.hasToken }}
|
||||||
|
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: CheckToken
|
needs: CheckToken
|
||||||
|
@ -62,14 +62,7 @@ RUN for verb in help \
|
|||||||
printf -- "%b" "#!/usr/bin/env sh\n/root/.acme.sh/acme.sh --${verb} --config-home /acme.sh \"\$@\"" >/usr/local/bin/--${verb} && chmod +x /usr/local/bin/--${verb} \
|
printf -- "%b" "#!/usr/bin/env sh\n/root/.acme.sh/acme.sh --${verb} --config-home /acme.sh \"\$@\"" >/usr/local/bin/--${verb} && chmod +x /usr/local/bin/--${verb} \
|
||||||
; done
|
; done
|
||||||
|
|
||||||
RUN printf "%b" '#!'"/usr/bin/env sh\n \
|
COPY entry.sh /
|
||||||
if [ \"\$1\" = \"daemon\" ]; then \n \
|
|
||||||
trap \"echo stop && killall crond && exit 0\" SIGTERM SIGINT \n \
|
|
||||||
crond && sleep infinity &\n \
|
|
||||||
wait \n \
|
|
||||||
else \n \
|
|
||||||
exec -- \"\$@\"\n \
|
|
||||||
fi" >/entry.sh && chmod +x /entry.sh
|
|
||||||
|
|
||||||
VOLUME /acme.sh
|
VOLUME /acme.sh
|
||||||
|
|
9
docker/entry.sh
Executable file
9
docker/entry.sh
Executable file
@ -0,0 +1,9 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
if [ "$1" = "daemon" ]; then
|
||||||
|
trap "echo stop && killall crond && exit 0" SIGTERM SIGINT
|
||||||
|
crond && sleep infinity &
|
||||||
|
wait
|
||||||
|
else
|
||||||
|
exec -- "$@"
|
||||||
|
fi
|
Loading…
x
Reference in New Issue
Block a user