Resources
-Here are some links to help you get started:
- -Next Steps
-What do you want to do next with your app?
- - - -ng generate component xyz-
ng add @angular/material-
ng add @angular/pwa-
ng add _____-
ng test-
ng build-
diff --git a/README.md b/README.md index 4f2c8eb..8b25e14 100644 --- a/README.md +++ b/README.md @@ -3,8 +3,9 @@ ## Futtatás Dockerrel A projekt mappájában adjuk ki a következő parancsot: ```bash -docker compose up --build # TODO: Frontend build & copy +docker compose up --build ``` +Ezután a http://localhost:3000/ cimen érhető el az oldal. ## Futtatás közvetlenül A projekt alapértelmezetten localhost:27017 cimen csatlakozik a MongoDB-hez, a hosztnév a DBHOST környezeti változóval állitható, vagy átirható az index.js fájl elején. @@ -13,8 +14,9 @@ A projekt mappájában adjuk ki a következő parancsokat: ```bash cd frontend npm install -# TODO: Frontend build +npm run build cd ../backend npm install npm start ``` +Ezután a http://localhost:3000/ cimen érhető el az oldal. diff --git a/client/.docker/Dockerfile b/client/.docker/Dockerfile new file mode 100644 index 0000000..546e54d --- /dev/null +++ b/client/.docker/Dockerfile @@ -0,0 +1,9 @@ +FROM node:lts + +RUN mkdir -p /home/node/app +WORKDIR /home/node/app + +ENTRYPOINT [ "/start.sh" ] + +COPY start.sh /start.sh +RUN chmod +x /start.sh diff --git a/client/.docker/start.sh b/client/.docker/start.sh new file mode 100644 index 0000000..03c7ce6 --- /dev/null +++ b/client/.docker/start.sh @@ -0,0 +1,7 @@ +#!/usr/bin/env bash + +cd client +echo "Installing packages" +npm install +echo "Running application" +npm run watch diff --git a/client/angular.json b/client/angular.json index 97f90e7..7b1f113 100644 --- a/client/angular.json +++ b/client/angular.json @@ -13,7 +13,7 @@ "build": { "builder": "@angular-devkit/build-angular:browser", "options": { - "outputPath": "dist/client", + "outputPath": "../server/public", "index": "src/index.html", "main": "src/main.ts", "polyfills": [ diff --git a/client/src/app/app.component.html b/client/src/app/app.component.html index e4e763e..4246f2c 100644 --- a/client/src/app/app.component.html +++ b/client/src/app/app.component.html @@ -1,483 +1,21 @@ - - - - - - - - - - - - -