diff options
author | Claudio D. Gasparini <claudio.gasparini@pantheon.tech> | 2021-02-04 09:33:28 +0100 |
---|---|---|
committer | Claudio D. Gasparini <claudio.gasparini@pantheon.tech> | 2021-02-04 12:58:14 +0100 |
commit | b1ccfce0b229d544bf08b1c197a2365b40369796 (patch) | |
tree | fd803e64387205147eda40668532a1aa053f7376 /docker-compose/README.md | |
parent | 1540a5809fff8477bfdb6f43fd6c475cf13c6d71 (diff) |
Decouple application configuration file
Agreement is that application configuration should live on OOM
- leave an example of the configuration file under docker
compose to run locally, instead of use OOM. Mainly for devs
- document on README how to run the app with IDE or with docker compose
- remove duplicate code on poms
Issue-ID: CPS-175
Signed-off-by: Claudio D. Gasparini <claudio.gasparini@pantheon.tech>
Change-Id: I328e89dba78cdf4d8abab51e3be5cb6d641064db
Diffstat (limited to 'docker-compose/README.md')
-rw-r--r-- | docker-compose/README.md | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/docker-compose/README.md b/docker-compose/README.md index ca395df07a..3d68c3ff4b 100644 --- a/docker-compose/README.md +++ b/docker-compose/README.md @@ -2,18 +2,33 @@ To run the application locally using `docker-compose`, execute following command from this `docker-compose` folder: -Generate the containers +Compile without generating the docker images + +```bash +mvn clean install -Pcps-docker -Pxnf-docker -Pcps-xnf-docker -Djib.skip +``` + +Generate the docker images ```bash mvn clean install -Pcps-docker -Pxnf-docker -Pcps-xnf-docker ``` -or for generate an specific type + +for generate a specific type of docker images ```bash mvn clean install -Pcps-docker ``` + Run the containers ```bash VERSION=0.0.1-SNAPSHOT DB_HOST=dbpostgresql DB_USERNAME=cps DB_PASSWORD=cps docker-compose up -d -```
\ No newline at end of file +``` + +Run application from Intellj IDE + +you need first to enable the maven profile desired under tab Maven +then go to Run -> Edit configurations + 1- Working directory -> select docker-compose folder e.g. ~/workspace/onap/cps/docker-compose/ + 2- Enviroment variables -> add variables configuration e.g. DB_HOST=127.0.0.1;DB_USERNAME=cps;DB_PASSWORD=cps
\ No newline at end of file |