Skip to content

Commit

Permalink
[s2i] do not check ENV in run script
Browse files Browse the repository at this point in the history
Delegate all validation work to the Lua CLI.
  • Loading branch information
mikz committed May 11, 2018
1 parent f673548 commit 8fce45b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 16 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Generate new policy scaffold from the CLI [PR #682](https://github.com/3scale/apicast/pull/682)
- 3scale batcher policy [PR #685](https://github.com/3scale/apicast/pull/685)

### Changed

- `THREESCALE_PORTAL_ENDPOINT` and `THREESCALE_CONFIG_FILE` are not required anymore [PR #702](https://github.com/3scale/apicast/pull/702)

## [3.2.0-rc2] - 2018-05-11

### Added
Expand Down
16 changes: 0 additions & 16 deletions gateway/.s2i/bin/run
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,6 @@ if [ -f "${luarocks}" ]; then
eval `/opt/app/bin/luarocks path`
fi

APICAST_CONFIGURATION_CACHE=${APICAST_CONFIGURATION_CACHE:-}

if [ "${APICAST_CONFIGURATION_CACHE:-0}" -gt 0 ] && [ "${APICAST_CONFIGURATION_CACHE}" -lt 60 ]; then
echo "APICAST_CONFIGURATION_CACHE should be 60 or greater, 0 or unset"
exit 1
fi

THREESCALE_PORTAL_ENDPOINT="${THREESCALE_PORTAL_ENDPOINT:-}"
THREESCALE_CONFIG_FILE="${THREESCALE_CONFIG_FILE:-}"

if [ -z "${THREESCALE_PORTAL_ENDPOINT:-}" ] && [ -z "${THREESCALE_CONFIG_FILE:-}" ]; then
# TODO: improve the error messsage
echo "missing either THREESCALE_PORTAL_ENDPOINT or THREESCALE_CONFIG_FILE environment variable"
exit 1
fi

if [ -f bin/apicast ]; then
apicast=bin/apicast
elif [ -f "${BASH_SOURCE%/*}/apicast" ]; then
Expand Down

0 comments on commit 8fce45b

Please sign in to comment.