[DCAE] INFO.yaml update
[dcaegen2/platform/inventory-api.git] / README.md
1 # DCAE Inventory
2
3 DCAE Inventory is a web service that provides a REST-API to obtain DCAE service and DCAE service type information.  You can find the design documentation [here](docs/Design.md).
4
5 ## Usage
6
7 ### Build Docker image
8
9 The following Maven command will build the Uber JAR, build the Docker image to the local machine registry and then push the same image to the specified remote registry.
10
11 ```
12 mvn clean package docker:build -DpushImageTag
13 ```
14
15 The image will be tagged with the project version found in the `pom.xml`.
16
17 ### Run via Docker
18
19 Execute this to run.
20
21 ```
22 docker run -p 8080:8080 -d -v <some local directory>/config.yml:/opt/config.yml --name dcae-inventory <docker registry>/dcae-inventory:<version>
23 ```
24
25 #### Running local Dockerized Postgres
26
27 The following is the docker command used to run a container of a postgres 9.5.2 image from the official repository:
28
29 ```
30  docker run --name dcae-postgres -e POSTGRES_PASSWORD=test123 -e PGDATA=/var/lib/postgresql/data/pgdata -v <local directory>:/var/lib/postgresql/data/pgdata -p 5432:5432 -d postgres:9.5.2
31  ```
32
33 The central postgres instance for 1607 will be using 9.5.2.
34
35 ## Swagger
36
37 To view the running service's swagger specification, execute the following:
38
39 ```
40 curl <hostname>:8080/swagger.json
41 ```
42
43 or
44
45 ```
46 curl <hostname>:8080/swagger.yaml
47 ```
48
49 To view it offline, an AsciiDoctor version is available [here](docs/API.adoc).