mirror of
https://github.com/camptocamp/odoo-cloud-platform.git
synced 2026-06-24 02:08:36 +00:00
feat: add prometheus + cloud_plateform azure
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
Cloud Platform Azure
|
||||
====================
|
||||
|
||||
Install addons specific to the Azure setup.
|
||||
|
||||
* The object storage is Azure blob storage
|
||||
@@ -0,0 +1 @@
|
||||
from . import models
|
||||
@@ -0,0 +1,24 @@
|
||||
# Copyright 2017-2021 Camptocamp SA
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html)
|
||||
|
||||
|
||||
{
|
||||
"name": "Cloud Platform Azure",
|
||||
"summary": "Addons required for the Camptocamp Cloud Platform on Azure",
|
||||
"version": "15.0.1.0.0",
|
||||
"author": "Camptocamp,Odoo Community Association (OCA)",
|
||||
"license": "AGPL-3",
|
||||
"category": "Extra Tools",
|
||||
"depends": [
|
||||
"cloud_platform",
|
||||
"attachment_azure",
|
||||
"monitoring_prometheus",
|
||||
],
|
||||
"excludes": [
|
||||
"cloud_platform_ovh",
|
||||
"cloud_platform_exoscale",
|
||||
],
|
||||
"website": "https://www.camptocamp.com",
|
||||
"data": [],
|
||||
"installable": True,
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
from . import cloud_platform
|
||||
@@ -0,0 +1,39 @@
|
||||
# Copyright 2016-2021 Camptocamp SA
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html)
|
||||
|
||||
import re
|
||||
import os
|
||||
|
||||
from openerp.osv import osv
|
||||
from openerp.addons.cloud_platform.models.cloud_platform import FilestoreKind
|
||||
from openerp.addons.cloud_platform.models.cloud_platform import PlatformConfig
|
||||
|
||||
AZURE_STORE_KIND = FilestoreKind("azure", "remote")
|
||||
|
||||
|
||||
class CloudPlatform(osv.osv):
|
||||
_inherit = "cloud.platform"
|
||||
|
||||
def _filestore_kinds(self):
|
||||
kinds = super(CloudPlatform, self)._filestore_kinds()
|
||||
kinds["azure"] = AZURE_STORE_KIND
|
||||
return kinds
|
||||
|
||||
def _platform_kinds(self):
|
||||
kinds = super(CloudPlatform, self)._platform_kinds()
|
||||
kinds.append("azure")
|
||||
return kinds
|
||||
|
||||
def _config_by_server_env_for_azure(self):
|
||||
fs_kinds = self._filestore_kinds()
|
||||
configs = {
|
||||
"prod": PlatformConfig(filestore=fs_kinds["azure"]),
|
||||
"integration": PlatformConfig(filestore=fs_kinds["azure"]),
|
||||
"labs": PlatformConfig(filestore=fs_kinds["azure"]),
|
||||
"test": PlatformConfig(filestore=fs_kinds["db"]),
|
||||
"dev": PlatformConfig(filestore=fs_kinds["db"]),
|
||||
}
|
||||
return configs
|
||||
|
||||
def install_azure(self, cr, uid, context=None):
|
||||
self.install(cr, uid, "azure", context)
|
||||
Reference in New Issue
Block a user