3 if [ -z $PG_CONN ]; then
4 echo "PG_CONN variable has not been set"
5 echo "PG_CONN contains the full postgresql URI"
9 mkdir -p ~/.config/dcae-cli
10 if [ ! -f ~/.config/dcae-cli/config.json ]; then
11 echo "Creating dcae-cli config"
12 # TODO: Make this into a variable that gets fed in via docker run
13 echo "{\"server_url\": \"https://git.onap.org/dcaegen2/platform/plain/mod\", \"user\": \"api\", \"db_url\": \"$PG_CONN\", \"cli_version\": \"2.12.0\", \"path_component_spec\": \"/component-json-schemas/component-specification/dcae-cli-v2/component-spec-schema.json\", \"path_data_format\": \"/component-json-schemas/data-format/dcae-cli-v1/data-format-schema.json\"}" > ~/.config/dcae-cli/config.json