Skip to content

Commit

Permalink
CMR-4132 - Added missing ingest public config and updated docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
oubiwann committed May 16, 2017
1 parent 6f01936 commit 9baedbe
Showing 1 changed file with 37 additions and 11 deletions.
48 changes: 37 additions & 11 deletions access-control-app/src/cmr/access_control/system.clj
Original file line number Diff line number Diff line change
Expand Up @@ -31,26 +31,52 @@
{:default nil
:parser cfg/maybe-long})

(defconfig log-level
"App logging level"
{:default "info"})

(defconfig access-control-public-protocol
"The protocol to use in documentation examples for the access-control application."
"The protocol to use for public access to the access-control application.
Note: this configuration value is used as-is in local, dev environments
and is overridden with ENV variables in remote deployments. In both cases,
this configuration information is utilized and required.
The name given after `defconfig` is important and is used when checking for
an ENV variable. The ENV variable for this configuration will be:
* CMR_ACCESS_CONTROL_PUBLIC_PROTOCOL"
{:default "http"})

(defconfig access-control-public-host
"The host name to use in links returned by the access-control application."
"The host name to use for public access to the access-control application.
Note: this configuration value is used as-is in local, dev environments
and is overridden with ENV variables in remote deployments. In both cases,
this configuration information is utilized and required.
The name given after `defconfig` is important and is used when checking for
an ENV variable. The ENV variable for this configuration will be:
* CMR_ACCESS_CONTROL_PUBLIC_HOST"
{:default "localhost"})

(defconfig access-control-public-port
"The port to use in links returned by the access-control application."
"The port to use for public access to the access-control application.
Note: this configuration value is used as-is in local, dev environments
and is overridden with ENV variables in remote deployments. In both cases,
this configuration information is utilized and required.
The name given after `defconfig` is important and is used when checking for
an ENV variable. The ENV variable for this configuration will be:
* CMR_ACCESS_CONTROL_PUBLIC_PORT"
{:default 3011
:type Long})

(defconfig log-level
"App logging level"
{:default "info"})

(defn public-conf
"Public access-control configuration used for generating example requests in documentation"
[]
(def public-conf
"Public access-control configuration used for generating proper link URLs in
dynamic content (templates), generating example requests in documentation,
and running the access-control service in the development environment for use
with integration tests."
{:protocol (access-control-public-protocol)
:host (access-control-public-host)
:port (access-control-public-port)
Expand Down Expand Up @@ -78,7 +104,7 @@
common-enabled/write-enabled-cache-key (common-enabled/create-write-enabled-cache)
common-health/health-cache-key (common-health/create-health-cache)}

:public-conf (public-conf)
:public-conf public-conf
:relative-root-url (transmit-config/access-control-relative-root-url)
:scheduler (jobs/create-scheduler
`system-holder
Expand Down

0 comments on commit 9baedbe

Please sign in to comment.