summaryrefslogtreecommitdiffstats
path: root/README.md
blob: d6bd1959c23fabcc063ccf719f390aef951eb023 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# Composition
Composition Refactoring

## Docker Build
```sh
$ docker login -u <user> -p <password> <docker_registry>
$ mkdir -p docker/target
$ cp dcaedt_be/target/dcae.war docker/target/dcae.war
$ cd docker
$ docker build --no-cache -t dcaed-be -f Dockerfile .
```
## Environment Configuration
The environment file must include the following new definition under "override_attributes":
  ``"SDC": {
        "BE":{
            "fqdn"      : "zldcrdm2sdc4cbe01.3f1a87.rdm2.tci.att.com"
        }
    },``
The environment json file should be injected into the docker by one of the following ways:
1. Place the json file under ```<host>:/data/environments```.
  Run the docker with volume:
  ```--volume /data/environments:/root/chef-solo/environments```
2. Use ``docker cp`` to copy the json file into the docker ```/root/chef-solo/environments```
## Docker Run
```sh
$ docker run -dit -p 8444:8444 --restart="always" --name=dcaed-be \
     --env ENVNAME=<environment_name> \
     --env JAVA_OPTIONS="-XX:MaxPermSize=256m -Xmx4713m \
           -Dconfig.home=\${JETTY_BASE}/config \
           -Dlog.home=/opt/logs/be \
           -Dlogging.config=\${JETTY_BASE}/config/dcae-be/logback-spring.xml" \
     [ --volume /data/environments:/root/chef-solo/environments ] \
     dcaed-be:latest \
     /bin/sh
```