diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 1e396d5..b17790c 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -32,6 +32,9 @@ jobs: uses: docker/metadata-action@v5 with: images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} + tags: | + # set latest tag for default branch + type=raw,value=latest,enable={{is_default_branch}} - name: Build and push the Docker image id: push diff --git a/Dockerfile b/Dockerfile index c358768..946ce83 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,15 +10,16 @@ WORKDIR /usr/src/app # Create the cache directory RUN mkdir -p ./cache && chown node:node ./cache -# Copy the current directory contents into the container at /usr/src/app -COPY --chown=node:node . . - -# Install any needed packages specified in package.json -RUN npm install && npm update # Define environment variable ENV NODE_ENV=production # Allow self-signed SSL certs ENV NODE_TLS_REJECT_UNAUTHORIZED=0 +# Copy the current directory contents into the container at /usr/src/app +COPY --chown=node:node . . + +# Install any needed packages specified in package.json +RUN npm install && npm update + # Run the app when the container launches ENTRYPOINT ["tail", "-f", "/dev/null"]