How to change or override openshift.conf in Python 3.3 cartridge

落花浮王杯 提交于 2020-01-03 04:38:06

问题


I want to deploy an open source project on OpenShift, I did not write the application. Openshift seems hard coded to look for the wsgi script here:

WSGIScriptAlias / "/var/lib/openshift/5320e280e0b8cd9e9a000362/app-root/runtime/repo/wsgi/application"

any attempt to change openshift.conf gets wiped out when the cartridge reloads or restarts.

I need this directive to be

WSGIScriptAlias / "/var/lib/openshift/5320e280e0b8cd9e9a000362/app-root/runtime/repo/myapp/wsgi.py"

I prefer not to have to hack the app, I don't want to have to worry about future changes upstream. The must be a way to change this setting but I've spent hours searching to no avail.


回答1:


Check out this release blog which explains how to use the OPENSHIFT_PYTHON_WSGI_APPLICATION environment variable to change your wsgi entry point: https://www.openshift.com/blogs/openshift-online-march-2014-release-blog



来源:https://stackoverflow.com/questions/22384096/how-to-change-or-override-openshift-conf-in-python-3-3-cartridge

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!