Skip to main content

Paas Service

蓝鲸 PaaS 平台增强服务框架

版本历史

详见 CHANGES.md。

使用指南

  1. 更新 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")]
  1. 单元测试

首先,安装 pytest、pytest-django。

然后执行 make test 运行所有单元测试。

Metadata

Release files for paas-service 3.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for paas-service 3.1.0
File Size Uploaded Provenance Actions
paas_service-3.1.0.tar.gz 22.0 kB Without provenance Details for paas_service-3.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for paas-service 3.1.0
File Interpreter ABI Platform Actions
paas_service-3.1.0-py3-none-any.whl Python 3 none any Details for paas_service-3.1.0-py3-none-any.whl

Total release size: 69.9 kB

Release files / paas_service-3.1.0.tar.gz

Download URL paas_service-3.1.0.tar.gz
Size 22.0 kB
Tags Source
SHA-256 checksum
How to use checksums
64d62894ae81b0e38661c58e5a90274e46708f662db707336c7ebafa7b939263
BLAKE2b-256 checksum
How to use checksums
8d00da8e159d3da1404f488ed2610e76372d656a1e7fc865aada2007eedd5acb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.13

Release files / paas_service-3.1.0-py3-none-any.whl

Download URL paas_service-3.1.0-py3-none-any.whl
Size 47.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
978d7ed1a2f9a74f627a0da03a83036667b8656f756797ca06369fa179087baf
BLAKE2b-256 checksum
How to use checksums
794f5ce5de46bf1d1b9a578ce6d914fce0e34f2e502a8aa57dec589f578a4015
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.13

Security for paas-service 3.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page