Set the API port from chart env var
For the deployment of armada, the entrypoint.sh needs to have the exposed uwsgi port matching the deployment of the api pod. This change sets the value in the pod.env.armada_api seciton so that the environment variable is set up by the chart rather than relying upon the default value set in the entrypoint.sh script. Change-Id: I7535abac7c252f5c65447476e02f8eb54647e966
This commit is contained in:
parent
3b879fc846
commit
9e81a317e2
|
@ -152,6 +152,9 @@ conf:
|
||||||
pod:
|
pod:
|
||||||
env:
|
env:
|
||||||
armada_api:
|
armada_api:
|
||||||
|
# ARMADA_API_PORT should = conf.armada.armada_api.bind_port in standard cases
|
||||||
|
- name: ARMADA_API_PORT
|
||||||
|
value: 8000
|
||||||
# - name: http_proxy
|
# - name: http_proxy
|
||||||
# value: http://proxy.example.com:8080
|
# value: http://proxy.example.com:8080
|
||||||
# - name: https_proxy
|
# - name: https_proxy
|
||||||
|
|
|
@ -19,7 +19,7 @@ set -ex
|
||||||
CMD="armada"
|
CMD="armada"
|
||||||
|
|
||||||
# Define port
|
# Define port
|
||||||
PORT=${PORT:-9000}
|
PORT=${ARMADA_API_PORT:-9000}
|
||||||
# How long uWSGI should wait for each Armada response
|
# How long uWSGI should wait for each Armada response
|
||||||
ARMADA_API_TIMEOUT=${ARMADA_API_TIMEOUT:-"3600"}
|
ARMADA_API_TIMEOUT=${ARMADA_API_TIMEOUT:-"3600"}
|
||||||
# Number of uWSGI workers to handle API requests
|
# Number of uWSGI workers to handle API requests
|
||||||
|
@ -32,7 +32,7 @@ ARMADA_API_THREADS=${ARMADA_API_THREADS:-"1"}
|
||||||
# server during import in `armada.api.server`.
|
# server during import in `armada.api.server`.
|
||||||
if [ "$1" = 'server' ]; then
|
if [ "$1" = 'server' ]; then
|
||||||
exec uwsgi \
|
exec uwsgi \
|
||||||
--http :${PORT} \
|
--http :${ARMADA_API_PORT} \
|
||||||
--http-timeout $ARMADA_API_TIMEOUT \
|
--http-timeout $ARMADA_API_TIMEOUT \
|
||||||
--enable-threads \
|
--enable-threads \
|
||||||
-L \
|
-L \
|
||||||
|
|
Loading…
Reference in New Issue