From 28e40c5ccb68a93efe14fabe564f8d8daec68c92 Mon Sep 17 00:00:00 2001 From: qiaofeng1227 <76487013@qq.com> Date: Fri, 28 Jul 2023 17:09:39 +0800 Subject: [PATCH] add --- appmanage/Dockerfile | 2 +- appmanage/api/service/manage.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/appmanage/Dockerfile b/appmanage/Dockerfile index 3523c27c..5b30af76 100644 --- a/appmanage/Dockerfile +++ b/appmanage/Dockerfile @@ -11,7 +11,7 @@ COPY static ./static COPY requirements.txt main.py database.sqlite ./ RUN apt update -# Install supervisords +# Install supervisords RUN apt install -y supervisor COPY config/supervisord.conf /etc/supervisor/conf.d/supervisord.conf COPY config/cmd.sh /cmd.sh diff --git a/appmanage/api/service/manage.py b/appmanage/api/service/manage.py index b08502dd..758437b4 100644 --- a/appmanage/api/service/manage.py +++ b/appmanage/api/service/manage.py @@ -84,7 +84,9 @@ def AppStoreCore(): least_version = json.loads(latest)['Requires at least'] now = shell_execute.execute_command_output_all("cat /data/apps/websoft9/version.json")['result'] now_version = json.loads(now)['VERSION'] - if now_version >= least_version and now_version <= most_version: + version_str = "now_version:" + now_version + " least_version:" + least_version + " most_version:" + most_version + myLogger.info_logger(version_str) + if float(now_version) >= float(least_version) and float(now_version) <= float(most_version): return "0" elif now_version < least_version: return "-1"