Skip to content

Commit

Permalink
feat:update
Browse files Browse the repository at this point in the history
  • Loading branch information
f-necas committed Feb 3, 2024
1 parent fa8c008 commit caf36a1
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
run: npm i

- name: Run docker-build
run: npx nx docker-build datahub
run: npx nx docker-build mel-datahub

- uses: docker/login-action@v1
name: Login to GitHub Container Registry
Expand Down
4 changes: 2 additions & 2 deletions apps/datahub/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,8 @@
"executor": "nx:run-commands",
"options": {
"commands": [
"nx build datahub",
"docker build --build-arg APP_NAME=datahub -f ./tools/docker/Dockerfile . -t ghcr.io/camptocamp/mel-dataplatform/datahub:latest"
"nx build mel-datahub",
"docker build --build-arg APP_NAME=plateforme -f ./tools/docker/Dockerfile . -t ghcr.io/camptocamp/mel-dataplatform/datahub:latest"
],
"parallel": false
}
Expand Down
3 changes: 1 addition & 2 deletions tools/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,11 @@ ENV CONFIG_DIRECTORY_OVERRIDE ""
ENV ASSETS_DIRECTORY_OVERRIDE ""
ENV CUSTOM_SCRIPTS_DIRECTORY ""

COPY dist/apps/datahub /usr/share/nginx/html/datahub
COPY dist/apps/datahub /usr/share/nginx/html/plateforme
COPY tools/docker/docker-entrypoint.sh /

# copy default NGINX conf & put the app name in it
COPY tools/docker/nginx.conf /etc/nginx/conf.d/default.conf
RUN sed -i "s/APP_NAME/datahub/" /etc/nginx/conf.d/default.conf

EXPOSE 80

Expand Down
2 changes: 1 addition & 1 deletion tools/docker/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ server {
}

location / {
try_files $uri $uri/ /APP_NAME/index.html;
try_files $uri $uri/ /plateforme/index.html;

add_header Cache-Control 'max-age=86400'; # 24h
}
Expand Down

0 comments on commit caf36a1

Please sign in to comment.