From 24871d08c11ba8924e0994e0fdecaf8927cdc078 Mon Sep 17 00:00:00 2001 From: akama-aka Date: Sun, 28 Apr 2024 05:57:14 +0200 Subject: [PATCH] Update image in README and rearrange Dockerfile Updated the image tag in the README file to use the development version from the ghcr.io repository. Also, rearranged Dockerfile by moving the environment variable declarations and adding new labels. The changes aim to enhance readability and maintainability of the Dockerfile. --- Dockerfile | 16 +++++++++------- README.md | 2 +- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index 242ed2d..4e6b30e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,17 +1,19 @@ FROM node:21-alpine LABEL authors="Akama Aka" +LABEL org.opencontainers.image.license="CC-BY-NC-ND 4.0" +ENV VERSION=1.0.0.2 \ + SERVER_PORT=8080 \ + SERVER_HOSTNAME=127.0.0.1 \ + SERVER_LOG_LEVEL=info \ + PATH_IDENTIFIER=akami-cgi +LABEL org.opencontainers.image.version=$VERSION +LABEL org.opencontainers.image.description="An custom CDN-CGI Server for 4xx,5xx Status Response Sites." RUN npm i -g fastify-cli RUN mkdir /opt/server RUN chown node:node /opt/server USER node WORKDIR /opt/server COPY --chown=node:node ./ /opt/server -ENV VERSION=1.0.0.2 \ - SERVER_PORT=8080 \ - SERVER_HOSTNAME=127.0.0.1 \ - SERVER_LOG_LEVEL=info \ - PATH_IDENTIFIER=akami-cgi - RUN npm i EXPOSE $SERVER_PORT -CMD [ "npm", "run"] \ No newline at end of file +CMD [ "npm", "run"] diff --git a/README.md b/README.md index c60a78c..7c5065b 100644 --- a/README.md +++ b/README.md @@ -62,7 +62,7 @@ Below is a sample docker-compose.yml that gives an example of how Docker Compose version: "3.8" services: cdn-cgi-server: - image: akami-cdn-cgi-server:1.0.0.2 + image: ghcr.io/akama-aka/akami-statuspage:development environment: - VERSION=1.0.0.2 - SERVER_PORT=8080