diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1fa35ea..cd3f56a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -135,7 +135,7 @@ jobs: platforms: linux/amd64, linux/arm/v6, linux/arm/v7, linux/arm64, linux/386, linux/ppc64le, linux/s390x context: . build-args: version=${{ needs.GenTag.outputs.value }} - push: false + push: true tags: | ghcr.io/${{ needs.RepoName.outputs.value }}:latest, ghcr.io/${{ needs.RepoName.outputs.value }}:${{ needs.GenTag.outputs.value }}, @@ -149,5 +149,9 @@ jobs: with: target: ghcr.io/${{ needs.RepoName.outputs.value }}:latest tag: 'slim' - - run: docker tag ghcr.io/${{ needs.RepoName.outputs.value }}:slim ghcr.io/${{ needs.RepoName.outputs.value }}:${{ needs.GenTag.outputs.value }}-slim - - run: docker image push --all-tags "ghcr.io/${{ needs.RepoName.outputs.value }}" + - run: | + docker tag ghcr.io/${{ needs.RepoName.outputs.value }}:slim ghcr.io/${{ needs.RepoName.outputs.value }}:${{ needs.GenTag.outputs.value }}-slim + docker tag ghcr.io/${{ needs.RepoName.outputs.value }}:slim ${{ needs.RepoName.outputs.value }}:slim + docker tag ghcr.io/${{ needs.RepoName.outputs.value }}:slim ${{ needs.RepoName.outputs.value }}:${{ needs.GenTag.outputs.value }}-slim + docker image rm ghcr.io/${{ needs.RepoName.outputs.value }}:latest + docker image push --all-tags "ghcr.io/${{ needs.RepoName.outputs.value }}" diff --git a/Dockerfile b/Dockerfile index 9a88745..854c7c1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,10 +3,10 @@ USER root COPY ./build /usr/share/nginx/html COPY ./default.conf /etc/nginx/conf.d/default.conf COPY ./set-env-variable.sh /docker-entrypoint.d -RUN chmod +x /docker-entrypoint.d/set-env-variable.sh -RUN dos2unix /docker-entrypoint.d/set-env-variable.sh -RUN chown -R 101 /usr/share/nginx/html -RUN chown -R 101 /etc/nginx/conf.d/default.conf +RUN chmod +x /docker-entrypoint.d/set-env-variable.sh && \ + dos2unix /docker-entrypoint.d/set-env-variable.sh && \ + chown -R 101 /usr/share/nginx/html && \ + chown -R 101 /etc/nginx/conf.d/default.conf USER 101 EXPOSE 8080 CMD ["nginx", "-g", "daemon off;"] \ No newline at end of file