A Django application for developing BK-PaaS add-on services.
Project description
Paas Service
蓝鲸 PaaS 平台增强服务框架
版本历史
详见 CHANGES.md。
使用指南
- 更新 settings:
INSTALLED_APPS = [
...
'paas_service',
...
]
MIDDLEWARE = [
...
'paas_service.auth.middleware.VerifiedClientMiddleware',
...
]
# 数据库敏感字段加密 Key
BKKRILL_ENCRYPT_SECRET_KEY = base64.b64encode(b'\x01' * 32)
# 与 PaaS 平台通信的 JWT 信息
PAAS_SERVICE_JWT_CLIENTS = [
{
"iss": "paas-v3",
"key": "123..........",
"algorithm": "HS256",
},
]
# 增强服务供应商类
PAAS_SERVICE_PROVIDER_CLS = "svc_xxx.vendor.provider.Provider"
# 增强服务实例信息渲染函数
PAAS_SERVICE_SVC_INSTANCE_RENDER_FUNC = "svc_xxx.vendor.render.render_instance_data"
# 设置语言,注意:目前国际化只支持: 简体中文 和 English
LANGUAGE_CODE = 'zh-cn'
LANGUAGES = [("zh-cn", "简体中文"), ("en", "English")]
- 单元测试
首先,安装 pytest、pytest-django。
然后执行 make test 运行所有单元测试。
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
paas_service-2.0.4.tar.gz
(22.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file paas_service-2.0.4.tar.gz.
File metadata
- Download URL: paas_service-2.0.4.tar.gz
- Upload date:
- Size: 22.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
640cc2dc40228a87fef11a4717eeb561742de78bfe467c63e309e3097c4308f7
|
|
| MD5 |
35fc3010c0340314aff7ddf745ad2c29
|
|
| BLAKE2b-256 |
121da2836216567703a0f4baa0687b5fbafa39bfd26ef3736225e49a354cab49
|
File details
Details for the file paas_service-2.0.4-py3-none-any.whl.
File metadata
- Download URL: paas_service-2.0.4-py3-none-any.whl
- Upload date:
- Size: 48.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
57f0410a7c9e3e7d3ea69560a676f1122c996831cc1a0ec0ac5ae943154d1750
|
|
| MD5 |
0200a545d71ad6e47941a2f66733e749
|
|
| BLAKE2b-256 |
23c55c20a86ededde89f6b8fb6dcb2194fa0dec0cb4b4bac2cca05fd1a9f3640
|