Add uwsgi support for ztevnfmdriver 18/85918/1
authorfujinhua <fu.jinhua@zte.com.cn>
Mon, 22 Apr 2019 01:43:03 +0000 (09:43 +0800)
committerfujinhua <fu.jinhua@zte.com.cn>
Mon, 22 Apr 2019 01:43:03 +0000 (09:43 +0800)
Change-Id: Ia9d48e73ac4b4270684e3134be944527d286173c
Issue-ID: VFC-1307
Signed-off-by: fujinhua <fu.jinhua@zte.com.cn>
zte/vmanager/requirements.txt
zte/vmanager/run.sh
zte/vmanager/stop.sh

index 8c114dc..d22c122 100644 (file)
@@ -16,4 +16,7 @@ flex>=6.11.1
 swagger-spec-validator>=2.1.0
 
 # for onap logging
-onappylog>=1.0.6
\ No newline at end of file
+onappylog>=1.0.6
+
+# uwsgi for parallel processing
+uwsgi
index 5c6e833..f0f0d48 100755 (executable)
@@ -18,7 +18,9 @@ if [ ! -x  $logDir  ]; then
        mkdir -p $logDir
 fi
 
-nohup python manage.py runserver 0.0.0.0:8410 > /dev/null &
+# nohup python manage.py runserver 0.0.0.0:8410 > /dev/null &
+
+nohup uwsgi --http :8410 -t 120 --module driver.wsgi --master --processes 4 &
 
 while [ ! -f $logDir/runtime_ztevnfmdriver.log ]; do
     sleep 1
index 8848e16..6f0b784 100755 (executable)
@@ -12,4 +12,7 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
-ps auxww | grep "manage.py runserver 0.0.0.0:8410" | awk '{print $2}' | xargs kill -9
+
+# ps auxww | grep "manage.py runserver 0.0.0.0:8410" | awk '{print $2}' | xargs kill -9
+
+ps auxww |grep 'uwsgi --http :8410 --module driver.wsgi --master' |awk '{print $2}' |xargs kill -9