OpsAny Overall Architecture¶
OpsAny consists of two parts: the PaaS platform and the SaaS applications.
-
PaaS platform: manages how SaaS applications run, including unified login, the developer center, and application updates. It also provides the databases and middleware used across the platform.
-
SaaS applications: every SaaS application uses the same development framework (built on a customized Django) and is deployed on the PaaS platform.
With some minor adjustments, any SaaS application can also run standalone without the PaaS platform.
PaaS Platform¶
OpsAny-PaaS is an operations development platform built on a customized version of Tencent's open-source bk-PaaS, letting operations developers create, develop, deploy, and manage operations SaaS applications quickly and easily.
It provides an application engine, front-end and back-end development frameworks, an API gateway, a scheduling engine, unified login, and shared components. This helps users build supporting tools and operations systems (collectively called SaaS applications) quickly, cheaply, and without operational overhead. It also automates and self-services everything from creating a SaaS application to deploying and maintaining it, so developers can focus on business logic.
We made the following changes on top of bk-PaaS:
- Added WebSocket support for the Bastion Host's underlying communication.
- Reworked appengine's SaaS upload and deployment logic to accept a specified SaaS Secret Key instead of relying on a whitelist.
- Reworked part of the login logic to work with unified permissions (RBAC).
- Reworked the paasagent code, adding configuration parameters and changing the default SaaS configuration files.
- Added ESB APIs and more.
The PaaS platform is deployed in Docker containers by default and starts automatically on boot.
- For details, see PaaS Architecture
SaaS Platform¶
Every OpsAny SaaS runs in its own container and has the following characteristics:
Tip
Keep the SaaS platform's Secret Key safe and never disclose it. (The Secret Key is generated randomly with the uuid command during deployment and stored as a hidden file in the installation directory's conf directory.)
- APPID: every SaaS has an APPID, configured in the
${APPID}-init.pyconfiguration file. - Secret Key: every SaaS has a Secret Key, created when the application is registered. You can view it in the Developer Center under Built-in Applications by clicking an application name and checking its configuration. It is configured in the
${APPID}-init.pyconfiguration file. - PaaS DOMAIN: every SaaS is configured with the platform domain, so changing the domain means changing the configuration of every SaaS. It is configured in the
${APPID}-init.pyconfiguration file.
The SaaS platform depends on the PaaS platform's unified login and ESB services. SaaS-to-SaaS communication also goes through ESB. OpsAny provides front-end and back-end development frameworks for SaaS; see the Developer Guide for more on customization.
- For details, see SaaS Architecture
