mirror of
https://github.com/camptocamp/odoo-cloud-platform.git
synced 2026-06-24 08:47:40 +00:00
Merge pull request #140 from camptocamp/12-fixes
cloud_platform: fix default config
This commit is contained in:
@@ -33,6 +33,9 @@ class FilestoreKind(object):
|
|||||||
file = 'file'
|
file = 'file'
|
||||||
|
|
||||||
|
|
||||||
|
DefaultConfig = PlatformConfig(filestore=FilestoreKind.db)
|
||||||
|
|
||||||
|
|
||||||
class CloudPlatform(models.AbstractModel):
|
class CloudPlatform(models.AbstractModel):
|
||||||
_name = 'cloud.platform'
|
_name = 'cloud.platform'
|
||||||
_description = 'cloud.platform'
|
_description = 'cloud.platform'
|
||||||
@@ -49,7 +52,7 @@ class CloudPlatform(models.AbstractModel):
|
|||||||
None
|
None
|
||||||
)
|
)
|
||||||
configs = configs_getter() if configs_getter else {}
|
configs = configs_getter() if configs_getter else {}
|
||||||
return configs.get(environment) or FilestoreKind.db
|
return configs.get(environment) or DefaultConfig
|
||||||
|
|
||||||
def _get_running_env(self):
|
def _get_running_env(self):
|
||||||
environment_name = config['running_env']
|
environment_name = config['running_env']
|
||||||
|
|||||||
Reference in New Issue
Block a user