Fix install for front

This commit is contained in:
Marc Ducobu 2021-05-31 23:04:52 +02:00
parent ef3766ae1c
commit c84d0cdfd6
4 changed files with 14 additions and 13 deletions

View File

@ -13,6 +13,7 @@ RUN mv TaxHub-1.7.3 taxhub
COPY patches/settings.ini /home/appuser/citizen/config/settings.ini COPY patches/settings.ini /home/appuser/citizen/config/settings.ini
COPY patches/frontend/src/conf /home/appuser/citizen/frontend/src/conf COPY patches/frontend/src/conf /home/appuser/citizen/frontend/src/conf
COPY patches/frontend/src/assets /home/appuser/citizen/frontend/src/assets COPY patches/frontend/src/assets /home/appuser/citizen/frontend/src/assets
COPY patches/frontend/server.ts /home/appuser/citizen/frontend/server.ts
WORKDIR /home/appuser/citizen/frontend WORKDIR /home/appuser/citizen/frontend

16
README
View File

@ -1,3 +1,5 @@
TODO FUSION entre README & README.md
# gl-geonature # gl-geonature
L'instance Geonature-Citizen de Champs-Libres. L'instance Geonature-Citizen de Champs-Libres.
@ -52,17 +54,9 @@ taxhub $ npm install
### Citizen-front ### Citizen-front
``` ```
docker-compose up -d citizen-front $ docker-compose run --rm citizen-front npm install
``` $ docker-compose run --rm citizen-front run build:i18n-ssr
$ docker-compose up -d citizen-front
Compilation du JS
```
$ docker-compose exec citizen-front bash
frontend $ npm install
frontend $ npm run build:fr
``` ```

View File

@ -1,3 +1,5 @@
TODO FUSION entre README & README.md
# gl-geonature # gl-geonature
L'instance Geonature-Citizen de Champs-Libres. L'instance Geonature-Citizen de Champs-Libres.
@ -26,9 +28,14 @@ $ git submodule foreach git pull git@github.com:Champs-Libres/GeoNature-citizen.
$ make doc $ make doc
### Builder le front (pour production) ### Builder le front (pour production) (avant de pouvoir faire le docker up)
``` ```
$ docker-compose run --rm citizen-front npm install
$ docker-compose run --rm citizen-front npm run build:i18n-ssr
$ docker-compose up -d citizen-front
```
$ docker-compose exec citizen bash $ docker-compose exec citizen bash
appuser@ab136184159a:~/citizen/$ cd frontend appuser@ab136184159a:~/citizen/$ cd frontend
appuser@ab136184159a:~/citizen/frontend$ npm run ng build -- --configuration=fr --prod appuser@ab136184159a:~/citizen/frontend$ npm run ng build -- --configuration=fr --prod

View File

@ -34,7 +34,6 @@ services:
- ./node_modules:/home/appuser/citizen/frontend/node_modules - ./node_modules:/home/appuser/citizen/frontend/node_modules
ports: ports:
- "4000:4000" - "4000:4000"
- "4200:4200"
command: npm run serve:ssr command: npm run serve:ssr
environment: environment:
# avoid goodle analytics question # avoid goodle analytics question