Skip to content

Commit

Permalink
fix deploy, improve dockerfile and fix build prod
Browse files Browse the repository at this point in the history
  • Loading branch information
candidosales committed Oct 20, 2024
1 parent 8b6d249 commit e3e6c22
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 24 deletions.
7 changes: 7 additions & 0 deletions client/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
**/node_modules/
.git
npm-debug.log
.coverage
.coverage.*
.env
.aws
29 changes: 13 additions & 16 deletions client/.firebase/hosting.ZGlzdC9kZXBlbmRlbmN5LXJlcG9ydA.cache
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
favicon.ico,1593386544696,a2aee5309d0b59b9b66384ccc3969a07fab1b320d0bf76f1b25047a051d7f774
index.html,1593386544758,03944f07899f8fb1dd9f59a595c3eedd106720cb0ebc458d9a08ac60e38aa36b
runtime-es2015.409e6590615fb48d139f.js,1593386531677,c4aa0a348c0dcf9c6af4b7b3f066d0599bcec97472ed96ab232c8dceb70607cb
3rdpartylicenses.txt,1593386530948,134f511fc9acc39a7ee2cebca043efb8780dc409c99455b4cb5fbb16f2c7af75
runtime-es5.409e6590615fb48d139f.js,1593386531734,c4aa0a348c0dcf9c6af4b7b3f066d0599bcec97472ed96ab232c8dceb70607cb
polyfills-es2015.95bb65e853d2781ac3bd.js,1593386531923,58cb2b2edc7ee597668522d32af2e7d60ae8aa09ecc7046035948d25d5c7dbc7
assets/i18n/en.json,1593386544730,36535579676022ae32e7f4cf901e869b16b3652a4fddd72b327305c2d7f606d0
assets/images/logo.svg,1593386544731,7dc9e5255cc39a2b1ecc4459822403f31ed49e7b0ca1b23c60776cd9c03bc023
assets/i18n/pt.json,1593386544730,a60433ea3d5580cc2c747912d4bf383a39347c59e7c1ea509134dfd9c91452e0
assets/config/data-test.json,1593386544725,adec3575d390241e4dd7592837cb16cdfa7357e23a070cd398b2ef3cd507a764
assets/config/data-original.json,1593386544722,e014fba99a033d66c75c734ec716ca4b36a850d58976cfef71f7da1cb5c3e4b1
assets/config/data.json,1593386544728,c5e317a8f7b6b2979e83f0094c60273757059460a68f6f82ebbc61cc054b369e
polyfills-es5.341d48ffc88eaeae911d.js,1593386536980,1c5ca43710c19dc84f2e57f613bba58001dd6d9889f580b15c27840d33dc0a5e
styles.0a6cdffdeb4effa94a93.css,1593386530949,b094047db46f1d5517c79a90774e4c7a5b0255dde150d544e3815420a6c74594
main-es5.ef08eaa92db6e43bf197.js,1593386543291,9923064961ff3761919dddf8eff7600fcd3c247ae5cc34470b7f5cfa53494c97
main-es2015.ef08eaa92db6e43bf197.js,1593386544685,d1358c648976c906e9fcf27da7c7d7e38665502de23748b894766a53bc8d8d7b
runtime.24c351dc1660746c.js,1729389303151,e3c2c39eaca26141197e8a84b4b3b6ccba9e9304a3349d0e73f4b567f4ec8e9d
favicon.ico,1729389303666,a2aee5309d0b59b9b66384ccc3969a07fab1b320d0bf76f1b25047a051d7f774
assets/images/logo.svg,1729389303672,2f6eb990476919ca098269ab04ad00cb7a39bc8f1cd9bb73a71991817953270f
polyfills.791414274f6b73fc.js,1729389303151,c6cfc952b3285f91690a05b90de95cd13ff5b1d4476f4f17fdc21adace0b1fbf
assets/i18n/pt.json,1729389303672,f9c042183ab2e421f454f6728529cb47a50c69e3701ba3d552f76b1520fb0654
assets/i18n/en.json,1729389303672,0e82291a19461d79d53dcfaa387dc81b371c713386c99f6c532a2d1028d55346
3rdpartylicenses.txt,1729389303151,58cc80555f9baa15c7ec1819cdf887d2ec7c010c3d95c653ee540333d6a58757
index.html,1729389303985,4f2be47a93952f76266ddf1e742b568c26c55fb1d8b329914bfdc6741501afd1
assets/config/data-test.json,1729389303670,770978a00570e6faf3aed1664e951b91ca4efbda690605653c5fa3d6b2dd4eb5
styles.0da7c488d5730cc7.css,1729389303151,3f6d402c67a937a8339e9baae44706c3159c163b6c5f956905ddd05c7bd003e9
assets/config/data.json,1729389303671,9b650543f0272af7270cda749ece119dd0a62877110e30fc1b2baa386820236b
assets/config/data-original.json,1729389303669,cdf9b86e6cf59242ea5f5c46e9de9b0cd3a59f8416af55b72454bee761e730f5
main.4dfee515e1e133e8.js,1729389303151,6cfc277a73ae4156470f6695156a18a6929a18cde308cf6d5d9ae39a933a3c93
10 changes: 4 additions & 6 deletions client/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
FROM node:20 AS compile-image

RUN npm install -g yarn
FROM node:21-alpine AS compile-image

WORKDIR /opt/ng
COPY package.json ./
RUN yarn install
RUN npm install

ENV PATH="./node_modules/.bin:$PATH"

COPY . ./
RUN ng build --prod
RUN ng build --configuration=production

FROM nginx
FROM nginx:alpine
# COPY docker/nginx/default.conf /etc/nginx/conf.d/default.conf
COPY --from=compile-image /opt/ng/dist/dependency-report /usr/share/nginx/html
2 changes: 1 addition & 1 deletion client/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ To get more help on the Angular CLI use `ng help` or go check out the [Angular C
## Deploy

```bash
ng deploy
npm run deploy
```

## Docker
Expand Down
2 changes: 1 addition & 1 deletion client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"test": "ng test",
"lint": "ng lint",
"serve:prod": "http-server dist/dependency-report -p 8081",
"deploy": "ng build --prod && firebase deploy"
"deploy": "ng build --configuration=production && firebase deploy"
},
"private": true,
"dependencies": {
Expand Down

0 comments on commit e3e6c22

Please sign in to comment.