diff options
author | Changjun Wang <310397125@qq.com> | 2019-03-28 06:23:28 +0000 |
---|---|---|
committer | Changjun Wang <310397125@qq.com> | 2019-03-28 06:23:28 +0000 |
commit | b322e0914ea5210e9e71d199ed1d41b0e7adddeb (patch) | |
tree | b3dc03e02c749a1e94db938978897e87ae375111 /lenovo/run.sh | |
parent | 9ac3a7a4882bf8d0a0814d8cff9b4abd62a74a9f (diff) |
Add https support for multicloud lenovo
The https endpoint can be enabled by setting env: SSL_ENABLED=true
Issue-ID: MULTICLOUD-538
Change-Id: I20ca09c431380d65098d42fadd1d92003cca69ba
Signed-off-by: Changjun Wang <310397125@qq.com>
Diffstat (limited to 'lenovo/run.sh')
-rwxr-xr-x | lenovo/run.sh | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lenovo/run.sh b/lenovo/run.sh index e5da37c3..45d109f7 100755 --- a/lenovo/run.sh +++ b/lenovo/run.sh @@ -17,7 +17,12 @@ memcached -d -m 2048 -u root -c 1024 -p 11211 -P /tmp/memcached1.pid export PYTHONPATH=lib/share #nohup python manage.py runserver 0.0.0.0:9010 2>&1 & -nohup uwsgi --http :9010 --module thinkcloud.wsgi --master --processes 4 & +#nohup uwsgi --http :9010 --module thinkcloud.wsgi --master --processes 4 & +if [ ${SSL_ENABLED} = "true" ]; then + nohup uwsgi --https :9010,thinkcloud/pub/ssl/cert/cert.crt,thinkcloud/pub/ssl/cert/cert.key,HIGH -t 120 --module thinkcloud.wsgi --master --processes 4 & +else + nohup uwsgi --http :9010 -t 120 --module thinkcloud.wsgi --master --processes 4 & +fi logDir="/var/log/onap/multicloud/openstack/lenovo" if [ ! -x $logDir ]; then @@ -27,4 +32,4 @@ while [ ! -f $logDir/thinkcloud.log ]; do sleep 1 done -tail -F $logDir/thinkcloud.log
\ No newline at end of file +tail -F $logDir/thinkcloud.log |