Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
INB
eTRANSAFE
pretox-app
Commits
2f91d7fd
Commit
2f91d7fd
authored
Jan 28, 2022
by
jcorvi
Browse files
Update Dockerfile
parent
d073fb0b
Pipeline
#27028
passed with stage
in 1 minute and 11 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Dockerfile
View file @
2f91d7fd
...
...
@@ -8,7 +8,7 @@ RUN npm update
COPY
. .
COPY
src/assets/index.template.html src/index.html
#RUN npm run build --prod
RUN
./node_modules/.bin/ng build
--prod
--base-href
/pretox/
RUN
./node_modules/.bin/ng build
--prod
--base-href
/pretox
tm.kh.svc
/
### STAGE 2: Run ###
FROM
nginx:1.21.6-alpine
#fix refresh
...
...
@@ -16,10 +16,14 @@ FROM nginx:1.21.6-alpine
RUN
rm
-rf
/usr/share/nginx/html/
*
&&
rm
-rf
/etc/nginx/nginx.conf
COPY
./nginx.conf /etc/nginx/nginx.conf
COPY
--from=build /usr/src/app/dist/my-app /usr/share/nginx/html/pretox
COPY
--from=build /usr/src/app/dist/my-app /usr/share/nginx/html/pretox
tm.kh.svc
#CMD ["/bin/sh", "-c", "envsubst < /usr/share/nginx/html/pretox/assets/env.template.js > /usr/share/nginx/html/pretox/assets/env.js && exec nginx -g 'daemon off;'"]
CMD
["/bin/sh", "-c", "envsubst < /usr/share/nginx/html/pretox/assets/env.template.js > /usr/share/nginx/html/pretox/assets/env.js && envsubst < /usr/share/nginx/html/pretox/index.html > /usr/share/nginx/html/pretox/index.html_2 && cp /usr/share/nginx/html/pretox/index.html_2 /usr/share/nginx/html/pretox/index.html && exec nginx-debug -g 'daemon off;'"]
CMD
["/bin/sh", "-c", "envsubst < /usr/share/nginx/html/pretoxtm.kh.svc/assets/env.template.js > /usr/share/nginx/html/pretoxtm.kh.svc/assets/env.js && envsubst < /usr/share/nginx/html/pretoxtm.kh.svc/index.html > /usr/share/nginx/html/pretoxtm.kh.svc/index.html_2 && cp /usr/share/nginx/html/pretoxtm.kh.svc/index.html_2 /usr/share/nginx/html/pretoxtm.kh.svc/index.html && exec nginx-debug -g 'daemon off;'"]
#CMD ["/bin/sh", "-c", "envsubst < /usr/share/nginx/html/pretox/assets/env.template.js > /usr/share/nginx/html/pretox/assets/env.js && envsubst < /usr/share/nginx/html/pretox/index.html > /usr/share/nginx/html/pretox/index.html_2 && cp /usr/share/nginx/html/pretox/index.html_2 /usr/share/nginx/html/pretox/index.html && exec nginx-debug -g 'daemon off;'"]
#CMD ["/bin/sh", "-c", "envsubst < /usr/share/nginx/html/pretox/assets/index.template.html > /usr/share/nginx/html/pretox/index.html && exec nginx -g 'daemon off;'"]
# && exec nginx-debug -g 'daemon off;'
#FROM nginx:1.17.1-alpine
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment