diff --git a/README.md b/README.md index 5b438c3..4b81db7 100644 --- a/README.md +++ b/README.md @@ -3,3 +3,7 @@ ## Project Members * Daniel Mader * Marcel Haag + +## Development server + +Execute 'c4po.sh' and all services will run on a dev server. diff --git a/c4po.sh b/c4po.sh new file mode 100755 index 0000000..49d6f71 --- /dev/null +++ b/c4po.sh @@ -0,0 +1,13 @@ +#!/bin/bash +baseDir=$(pwd)"/" +echo" +_______ _______ _______ _ _ ______ _____ _______ __ __ +|______ |______ | | | |_____/ | | \_/ +______| |______ |_____ |_____| | \_ __|__ | | _/_/_/ _/ _/ _/_/_/ _/_/ + _/ _/ _/ _/ _/ _/ _/ + _/ _/_/_/_/ _/_/_/ _/ _/ + _/ _/ _/ _/ _/ + _/_/_/ _/ _/ _/_/ +" +docker-compose up --build +#docker-compose up diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..d3bb086 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,24 @@ +version: '3.1' + +services: + api: + build: './security-c4po-api' + image: security-c4po-api:latest + container_name: security-c4po-api + deploy: + resources: + limits: + memory: "1G" + ports: + - '8443:8443' + + angular: + build: './security-c4po-angular' + image: security-c4po-angular:latest + container_name: security-c4po-angular + deploy: + resources: + limits: + memory: "1G" + ports: + - '4200:4200' diff --git a/security-c4po-angular/Dockerfile b/security-c4po-angular/Dockerfile new file mode 100644 index 0000000..c42b1b9 --- /dev/null +++ b/security-c4po-angular/Dockerfile @@ -0,0 +1,19 @@ +# base image +FROM node:12.13.1 + +# set working directory +WORKDIR /app + +# add `/app/node_modules/.bin` to $PATH +ENV PATH /app/node_modules/.bin:$PATH + +# install and cache app dependencies +COPY package.json /app/package.json +RUN npm install +RUN npm install -g @angular/cli@10.2.0 + +# add app +COPY . /app + +# start app +CMD ng serve --host 0.0.0.0 diff --git a/security-c4po-angular/src/index.html b/security-c4po-angular/src/index.html index 6f15eb2..860234a 100644 --- a/security-c4po-angular/src/index.html +++ b/security-c4po-angular/src/index.html @@ -2,7 +2,7 @@
-