From a31775dd23dd56bd12c2e005193ba0c048035e66 Mon Sep 17 00:00:00 2001 From: ibuler Date: Wed, 27 Mar 2019 17:46:35 +0800 Subject: [PATCH] =?UTF-8?q?[Update]=20=E6=95=B4=E7=90=86=20copyright=20?= =?UTF-8?q?=E5=92=8C=20=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/__init__.py | 1 - apps/jumpserver/const.py | 3 +++ apps/jumpserver/context_processor.py | 6 +++++- apps/jumpserver/settings.py | 13 +++++++------ apps/locale/zh/LC_MESSAGES/django.mo | Bin 70888 -> 70884 bytes apps/locale/zh/LC_MESSAGES/django.po | 10 +++++----- apps/templates/_copyright.html | 2 +- apps/templates/_footer.html | 4 ++-- jms | 3 ++- 9 files changed, 25 insertions(+), 17 deletions(-) create mode 100644 apps/jumpserver/const.py diff --git a/apps/__init__.py b/apps/__init__.py index f62c895b3..c2e888094 100644 --- a/apps/__init__.py +++ b/apps/__init__.py @@ -1,4 +1,3 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- # -__version__ = "1.4.9" diff --git a/apps/jumpserver/const.py b/apps/jumpserver/const.py new file mode 100644 index 000000000..808e15527 --- /dev/null +++ b/apps/jumpserver/const.py @@ -0,0 +1,3 @@ +# -*- coding: utf-8 -*- +# +VERSION = '1.4.9' diff --git a/apps/jumpserver/context_processor.py b/apps/jumpserver/context_processor.py index f8967adcf..10cf48a56 100644 --- a/apps/jumpserver/context_processor.py +++ b/apps/jumpserver/context_processor.py @@ -1,6 +1,8 @@ # -*- coding: utf-8 -*- # from django.contrib.staticfiles.templatetags.staticfiles import static +from django.conf import settings +from django.utils.translation import gettext_lazy as _ def jumpserver_processor(request): @@ -11,7 +13,9 @@ def jumpserver_processor(request): 'LOGO_TEXT_URL': static('img/logo_text.png'), 'LOGIN_IMAGE_URL': static('img/login_image.png'), 'FAVICON_URL': static('img/facio.ico'), - 'JMS_TITLE': 'Jumpserver' + 'JMS_TITLE': 'Jumpserver', + 'VERSION': settings.VERSION, + 'COPYRIGHT': _('Beijing Duizhan Tech, Inc.') + ' © 2014-2019' } return context diff --git a/apps/jumpserver/settings.py b/apps/jumpserver/settings.py index d516c097c..bd46309d1 100644 --- a/apps/jumpserver/settings.py +++ b/apps/jumpserver/settings.py @@ -12,25 +12,24 @@ https://docs.djangoproject.com/en/1.10/ref/settings/ import os import sys -import socket import ldap from django.urls import reverse_lazy +from .const import VERSION from .conf import load_user_config # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) PROJECT_DIR = os.path.dirname(BASE_DIR) sys.path.append(PROJECT_DIR) -from apps import __version__ -VERSION = __version__ CONFIG = load_user_config() LOG_DIR = os.path.join(PROJECT_DIR, 'logs') JUMPSERVER_LOG_FILE = os.path.join(LOG_DIR, 'jumpserver.log') ANSIBLE_LOG_FILE = os.path.join(LOG_DIR, 'ansible.log') GUNICORN_LOG_FILE = os.path.join(LOG_DIR, 'gunicorn.log') +VERSION = VERSION if not os.path.isdir(LOG_DIR): os.makedirs(LOG_DIR) @@ -163,7 +162,7 @@ MESSAGE_STORAGE = 'django.contrib.messages.storage.cookie.CookieStorage' DB_OPTIONS = {} DATABASES = { 'default': { - 'ENGINE': 'django.db.backends.{}'.format(CONFIG.DB_ENGINE), + 'ENGINE': 'django.db.backends.{}'.format(CONFIG.DB_ENGINE.lower()), 'NAME': CONFIG.DB_NAME, 'HOST': CONFIG.DB_HOST, 'PORT': CONFIG.DB_PORT, @@ -174,8 +173,10 @@ DATABASES = { } } DB_CA_PATH = os.path.join(PROJECT_DIR, 'data', 'ca.pem') -if CONFIG.DB_ENGINE == 'mysql' and os.path.isfile(DB_CA_PATH): - DB_OPTIONS['ssl'] = {'ca': DB_CA_PATH} +if CONFIG.DB_ENGINE.lower() == 'mysql': + DB_OPTIONS['init_command'] = "SET sql_mode='STRICT_TRANS_TABLES'" + if os.path.isfile(DB_CA_PATH): + DB_OPTIONS['ssl'] = {'ca': DB_CA_PATH} # Password validation diff --git a/apps/locale/zh/LC_MESSAGES/django.mo b/apps/locale/zh/LC_MESSAGES/django.mo index 5bcb3f572fb8cd096ce16deb94d3346aaa363959..6a7551a66ae5ddfe18bbda05e71662b08e59d4fe 100644 GIT binary patch delta 16553 zcmYk@37n2q|Htv`W`-GKhB3xA7#U;iVn`W`VeFd8E@R(?Ci@a@d&v@ADcU3wqAU-E zLKr=irLu%5B}I6YRCv_?^S#gSdAox!P`JL-r=lsrcUH43$|Ih2fF0Bh&JTO?y z^SrmadtM}di1D}&3*grnjo)GvUdIx62NSXASTTN2jC^Kvm*i^3QRZ(v6(*4Oho;UIGdsy@1(=QY5-s05awR_qPb zioA{5x^U!vOG#Y|K-+WQu$M8_g45%lI#NTlKg)ShfXWqc5|5+_g{ok4BEx2V0n zhFbD_s3k4NiBf%eRJ)p}ej1{#x5i4?8MShgFoyBH*%WG0;iLBS6I2JEp>FsZwFUQ4 zdl@s(?PWDAL);X#-X# zZv4{x#=LCaH1DDwv#=p8O66#g_OkY6X5ntx#BSnA_t7)Y8_m zxGCys=xRQJTA^vEnY@e|@Ewc)g%QLDPzfACy@*bt2KpJ5=s$Kn`Uy8)FrI>zqLNu3 z)j>apvFnUC_Vr6 zDX8O&Pz8I6>SzG!EQ~f6pgLTGQMd!uQ66f5)2J2s9<`!ZQCoEnm0;9JH<8k)rzQyt z>-n!jK}%I%71#tdKs!`N-B1Y)MGZ6owE{COejT+!Yf<-aLG`x>mEgZoiJe6y^gZfq z{f0s9MS&+>hS8{j6HpCPFa{f-GH!`#-wr>*j;M}{BJ^RO+h#hZ8w)zPJ=TnE=t3H*l9cn38=!BLhts(lK!!UwS$PPF<} zsDwA59^ZeBV*Pc>cT!Omk71}|)IbGCyDf-8Wt@oWpc-nRx@HYl$1}W$i_d{hg5w!)=Py;=OO5_EM!R4rd*P_~QMz#9@)ou@J0tZoN z;RIH|ix%e_>+UatY9A~`K^-Kb22QaHsi?#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zUdlmSw}oQ@Ti>x?Z=Im17zbRpqLOT)hh;y_Z{- zjZLLCfg1f3r*@V%D zX;mm*uM_>m^1GX>s^PQrZtQ*2s=fa?uVm}x{vzJ{t;_nK@y@hf9XpNo4BG$yPgQS0 zo67#a-mW&4L!PE#ig&rqNPo1~t!*cN2X9l`2J!P$%T={3>vrU}hq$okZ6{o5OJ lFTJz)xB1h4TRHFYibXlIHs&n+aJ%>EseIe#9q!TUe*h5!INbmM diff --git a/apps/locale/zh/LC_MESSAGES/django.po b/apps/locale/zh/LC_MESSAGES/django.po index f0494f3de..dbbd4ebbd 100644 --- a/apps/locale/zh/LC_MESSAGES/django.po +++ b/apps/locale/zh/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Jumpserver 0.3.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-03-27 12:48+0800\n" +"POT-Creation-Date: 2019-03-27 17:33+0800\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: ibuler \n" "Language-Team: Jumpserver team\n" @@ -2322,6 +2322,10 @@ msgstr "" msgid "Special char not allowed" msgstr "不能包含特殊字符" +#: jumpserver/context_processor.py:18 +msgid "Beijing Duizhan Tech, Inc." +msgstr "北京堆栈科技有限公司" + #: jumpserver/views.py:185 msgid "" "

Luna is a separately deployed program, you need to deploy Luna, coco, " @@ -3347,10 +3351,6 @@ msgstr "创建录像存储" msgid "Create command storage" msgstr "创建命令存储" -#: templates/_copyright.html:2 templates/_footer.html:8 -msgid " Beijing Duizhan Tech, Inc. " -msgstr " 北京堆栈科技有限公司 " - #: templates/_header_bar.html:31 msgid "Help" msgstr "帮助" diff --git a/apps/templates/_copyright.html b/apps/templates/_copyright.html index 327e67bd3..772c24cc5 100644 --- a/apps/templates/_copyright.html +++ b/apps/templates/_copyright.html @@ -1,2 +1,2 @@ {% load i18n %} -Copyright {% trans ' Beijing Duizhan Tech, Inc. ' %} © 2014-2019 \ No newline at end of file +Copyright {{ COPYRIGHT }} \ No newline at end of file diff --git a/apps/templates/_footer.html b/apps/templates/_footer.html index 869ea76a6..21ed61e77 100644 --- a/apps/templates/_footer.html +++ b/apps/templates/_footer.html @@ -1,10 +1,10 @@ {% load i18n %} diff --git a/jms b/jms index bb10b7796..43c345406 100755 --- a/jms +++ b/jms @@ -13,7 +13,8 @@ BASE_DIR = os.path.dirname(os.path.abspath(__file__)) sys.path.insert(0, BASE_DIR) try: - from apps import __version__ + from apps.jumpserver import const + __version__ = const.VERSION except ImportError as e: print("Not found __version__: {}".format(e)) print("Sys path: {}".format(sys.path))