[SEBA-461][WIP] Adding xos-migrate to the XOS Toolchain
Change-Id: I3a6e2a86b804efe207e7a71109763b11ba9acdaa
diff --git a/VERSION b/VERSION
index 584f466..7ec3b24 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.1.47
+2.1.48
diff --git a/containers/chameleon/Dockerfile.chameleon b/containers/chameleon/Dockerfile.chameleon
index 43291f2..5889507 100644
--- a/containers/chameleon/Dockerfile.chameleon
+++ b/containers/chameleon/Dockerfile.chameleon
@@ -13,7 +13,7 @@
# limitations under the License.
# xosproject/chameleon
-FROM xosproject/xos-base:2.1.47
+FROM xosproject/xos-base:2.1.48
# xos-base already has protoc and dependencies installed
@@ -52,4 +52,3 @@
# Exposing process and default entry point
CMD ["python", "/chameleon/chameleon/main.py"]
-
diff --git a/containers/xos/Dockerfile.client b/containers/xos/Dockerfile.client
index 1649b6f..42b2e76 100644
--- a/containers/xos/Dockerfile.client
+++ b/containers/xos/Dockerfile.client
@@ -13,7 +13,8 @@
# limitations under the License.
# xosproject/xos-client
-FROM xosproject/xos-libraries:2.1.47
+FROM xosproject/xos-libraries:2.1.48
+
# Install XOS client
COPY lib/xos-api /tmp/xos-api
diff --git a/containers/xos/Dockerfile.libraries b/containers/xos/Dockerfile.libraries
index 6aa5170..f82db50 100644
--- a/containers/xos/Dockerfile.libraries
+++ b/containers/xos/Dockerfile.libraries
@@ -13,7 +13,7 @@
# limitations under the License.
# xosproject/xos-libraries
-FROM xosproject/xos-base:2.1.47
+FROM xosproject/xos-base:2.1.48
# Add libraries
COPY lib /opt/xos/lib
diff --git a/containers/xos/Dockerfile.synchronizer-base b/containers/xos/Dockerfile.synchronizer-base
index a2ff068..c4c47a7 100644
--- a/containers/xos/Dockerfile.synchronizer-base
+++ b/containers/xos/Dockerfile.synchronizer-base
@@ -13,7 +13,7 @@
# limitations under the License.
# xosproject/xos-synchronizer-base
-FROM xosproject/xos-client:2.1.47
+FROM xosproject/xos-client:2.1.48
COPY xos/synchronizers/new_base /opt/xos/synchronizers/new_base
COPY xos/xos/logger.py /opt/xos/xos/logger.py
diff --git a/containers/xos/Dockerfile.xos-core b/containers/xos/Dockerfile.xos-core
index f6ea4e6..cf04559 100644
--- a/containers/xos/Dockerfile.xos-core
+++ b/containers/xos/Dockerfile.xos-core
@@ -13,7 +13,7 @@
# limitations under the License.
# xosproject/xos-core
-FROM xosproject/xos-libraries:2.1.47
+FROM xosproject/xos-libraries:2.1.48
# Install XOS
ADD xos /opt/xos
@@ -49,4 +49,3 @@
org.label-schema.vcs-ref=$org_label_schema_vcs_ref \
org.label-schema.build-date=$org_label_schema_build_date \
org.opencord.vcs-commit-date=$org_opencord_vcs_commit_date
-
diff --git a/docs/dev/xosmigrate.md b/docs/dev/xosmigrate.md
new file mode 100644
index 0000000..668c038
--- /dev/null
+++ b/docs/dev/xosmigrate.md
@@ -0,0 +1,136 @@
+# Generating migrations for XOS and Services
+
+This document describes how to use the XOS toolchain to generate basic migrations
+for service models. The autogenerated migrations can later be extended with custom
+logic to support more complex scenarios.
+
+> NOTE from now on we assume you have obtained the code as described in
+> [this guide](https://guide.opencord.org/developer/getting_the_code.html) and the
+> entire tree is now available in `~/cord`
+
+## Install the XOS Toolchain
+
+The XOS toolchain consists of a set of python libraries. There is an helper script
+to install the toolchain in the XOS repo, so just execute:
+
+```bash
+cd ~/cord/orchestration/xos
+bash scripts/setup_venv.sh
+```
+
+## Generate the migrations
+
+Once the toolchain is available, you'll be able to generate migrations for the services (or the core).
+The `xos-migrate` command is now available and you can see the options by running:
+
+```bash
+xos-migrate -h
+usage: xos-migrate [-h] -s SERVICE_NAMES [-r REPO_ROOT] [-v]
+
+XOS Migrations
+
+optional arguments:
+ -h, --help show this help message and exit
+ -r REPO_ROOT, --repo REPO_ROOT
+ The location of the folder containing the CORD repo
+ root (default to ~/cord)
+ -v, --verbose increase log verbosity
+
+required arguments:
+ -s SERVICE_NAMES, --service SERVICE_NAMES
+ The name of the folder containing the service in
+ cord/orchestration/xos_services
+```
+
+Supposing that your code is living under `~/Sites/cord` and you want to generate migrations
+for `core` and `fabric`, this is the command you'll run:
+
+```bash
+xos-migrate -r ~/Sites/cord -s core -s fabric
+```
+
+If no migrations were present for your service you'll see a new folder `migrations`
+that is a sibling of `models` containing a file `0001-initial.py`.
+If the service already had migrations you'll see a new file in that folder,
+for example: `0002-fabricservice_fullname.py`
+
+> NOTE that all the migration files needs to be committed together with the code
+> as they'll be loaded into the core together with the models.
+
+## Customize the migrations
+
+The autogenerated migrations only operates on the database altering tables, they
+won't make any modifications to the data. You can write custom code to do that,
+following this example.
+
+We assume you already have a model called `FabricService` that has two properties:
+`first_name` and `last_name`.
+
+As part of your changes you want to add a third property called `full_name` that
+is defined as `first_name` + `last_name`.
+
+This is the migration code that the tool will generate:
+
+```python
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('fabric', '0001_initial'),
+ ]
+
+ operations = [
+ migrations.AddField(
+ model_name='fabricservice',
+ name='full_name',
+ field=models.TextField(blank=True, null=True),
+ ),
+ ]
+```
+
+To migrate the data, you need to add a custom operation in your migration.
+This can be done defining a custom method `forwards` as:
+
+```python
+def forwards(apps, schema_editor):
+ MyModel = apps.get_model('myapp', 'MyModel')
+ for row in MyModel.objects.all():
+ row.full_name = "%s %s" % (row.first_name, row.last_name)
+ row.save(update_fields=['full_name'])
+```
+
+and adding it to the `operations` list.
+
+Here is a complete example of the customized migration:
+
+```python
+def forwards(apps, schema_editor):
+ MyModel = apps.get_model('myapp', 'MyModel')
+ for row in MyModel.objects.all():
+ row.full_name = "%s %s" % (row.first_name, row.last_name)
+ row.save(update_fields=['full_name'])
+
+class Migration(migrations.Migration):
+
+
+ dependencies = [
+ ('fabric', '0001_initial'),
+ ]
+
+ operations = [
+ migrations.AddField(
+ model_name='fabricservice',
+ name='full_name',
+ field=models.TextField(blank=True, null=True),
+ ),
+ migrations.RunPython(forwards),
+ ]
+```
+
+For more informations about migrations you can refer to the official
+[Django guide](https://docs.djangoproject.com/en/2.1/howto/writing-migrations/).
+
+Here are some good reads about migrations:
+
+- <https://realpython.com/django-migrations-a-primer/#creating-migrations>
+- <https://realpython.com/data-migrations/>
\ No newline at end of file
diff --git a/lib/xos-migrate/.gitignore b/lib/xos-migrate/.gitignore
new file mode 100644
index 0000000..ed8b98a
--- /dev/null
+++ b/lib/xos-migrate/.gitignore
@@ -0,0 +1,6 @@
+build
+dist
+XosMigrate.egg-info
+.coverage
+coverage.xml
+cover
diff --git a/lib/xos-migrate/MANIFEST.in b/lib/xos-migrate/MANIFEST.in
new file mode 100644
index 0000000..a38c6ba
--- /dev/null
+++ b/lib/xos-migrate/MANIFEST.in
@@ -0,0 +1,2 @@
+include xosmigrate/migration_cfg_schema.yaml
+include xosmigrate/migration_cfg.yaml
diff --git a/lib/xos-migrate/bin/xos-migrate b/lib/xos-migrate/bin/xos-migrate
new file mode 100644
index 0000000..574bc40
--- /dev/null
+++ b/lib/xos-migrate/bin/xos-migrate
@@ -0,0 +1,5 @@
+#!/usr/bin/env python
+
+# from xosmigrate import run
+from xosmigrate.main import run
+run()
diff --git a/lib/xos-migrate/setup.py b/lib/xos-migrate/setup.py
new file mode 100644
index 0000000..fe795de
--- /dev/null
+++ b/lib/xos-migrate/setup.py
@@ -0,0 +1,37 @@
+#!/usr/bin/env python
+
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+try:
+ from xosutil.autoversion_setup import setup_with_auto_version as setup
+except ImportError:
+ # xosutil is not installed. Expect this to happen when we build an egg, in which case xosgenx.version will
+ # automatically have the right version.
+ from setuptools import setup
+
+from xosgenx.version import __version__
+
+setup(
+ name="XosMigrate",
+ version=__version__,
+ description="XOS Migrations Toolkit",
+ author="Matteo Scandolo",
+ author_email="teo@opennetworking.org",
+ packages=["xosmigrate"],
+ scripts=["bin/xos-migrate"],
+ include_package_data=True,
+ # TODO add all deps to the install_requires section
+ install_requires=[],
+)
diff --git a/lib/xos-migrate/xosmigrate/__init__.py b/lib/xos-migrate/xosmigrate/__init__.py
new file mode 100644
index 0000000..0612f4f
--- /dev/null
+++ b/lib/xos-migrate/xosmigrate/__init__.py
@@ -0,0 +1,14 @@
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+import main
diff --git a/lib/xos-migrate/xosmigrate/main.py b/lib/xos-migrate/xosmigrate/main.py
new file mode 100644
index 0000000..e6901e2
--- /dev/null
+++ b/lib/xos-migrate/xosmigrate/main.py
@@ -0,0 +1,354 @@
+#!/usr/bin/python
+
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# TO RUN
+# source scripts/setup_venv.sh
+# xos-migrate [-s <service-name>] [-r ~/cord]
+# eg: xos-migrate -r ~/Sites/cord -s core -s fabric
+
+# TODO
+# - add support for services that are in the cord/orchestration/profiles folders
+# - add support to specify a name to be given to the generated migration (--name parameter in django makemigrations)
+# - add support to generate empty migrations (needed for data-only migrations)
+
+import os
+import sys
+import argparse
+import yaml
+import shutil
+from xosgenx.generator import XOSProcessor, XOSProcessorArgs
+from xosconfig import Config
+from multistructlog import create_logger
+
+
+def get_abs_path(dir_):
+ if os.path.isabs(dir_):
+ return dir_
+ if dir_[0] == '~' and not os.path.exists(dir_):
+ dir_ = os.path.expanduser(dir_)
+ return os.path.abspath(dir_)
+ return os.path.dirname(os.path.realpath(__file__)) + "/" + dir_
+
+
+def print_banner(root):
+ log.info(r"---------------------------------------------------------------")
+ log.info(r" _ __ ")
+ log.info(r" _ ______ _____ ____ ___ (_)___ __________ _/ /____ ")
+ log.info(r" | |/_/ __ \/ ___/_____/ __ `__ \/ / __ `/ ___/ __ `/ __/ _ \ ")
+ log.info(r" _> </ /_/ (__ )_____/ / / / / / / /_/ / / / /_/ / /_/ __/ ")
+ log.info(r"/_/|_|\____/____/ /_/ /_/ /_/_/\__, /_/ \__,_/\__/\___/ ")
+ log.info(r" /____/ ")
+ log.info(r"---------------------------------------------------------------")
+ log.debug("CORD repo root", root=root)
+ log.debug("Storing logs in: %s" % os.environ["LOG_FILE"])
+ # log.debug("Config schema: %s" % os.environ['XOS_CONFIG_SCHEMA'])
+ # log.debug("Config: %s" % os.environ['XOS_CONFIG_FILE'])
+ log.debug(r"---------------------------------------------------------------")
+
+
+def generate_core_models(core_dir):
+ core_xproto = os.path.join(core_dir, "core.xproto")
+
+ args = XOSProcessorArgs(
+ output=core_dir,
+ target="django.xtarget",
+ dest_extension="py",
+ write_to_file="model",
+ files=[core_xproto],
+ )
+ XOSProcessor.process(args)
+
+ security_args = XOSProcessorArgs(
+ output=core_dir,
+ target="django-security.xtarget",
+ dest_file="security.py",
+ write_to_file="single",
+ files=[core_xproto],
+ )
+
+ XOSProcessor.process(security_args)
+
+ init_args = XOSProcessorArgs(
+ output=core_dir,
+ target="init.xtarget",
+ dest_file="__init__.py",
+ write_to_file="single",
+ files=[core_xproto],
+ )
+ XOSProcessor.process(init_args)
+
+
+def find_xproto_in_folder(path):
+ """
+ Recursively iterate a folder tree to look for any xProto file.
+ We use this function in case that the name of the xProto is different from the name of the folder (eg: olt-service)
+ :param path: the root folder to start the search
+ :return: [string]
+ """
+ xprotos = []
+ for fn in os.listdir(path):
+ # skip hidden files and folders. plus other useless things
+ if fn.startswith(".") or fn == "venv-xos" or fn == "htmlcov":
+ continue
+ full_path = os.path.join(path, fn)
+ if fn.endswith(".xproto"):
+ xprotos.append(full_path)
+ elif os.path.isdir(full_path):
+ xprotos = xprotos + find_xproto_in_folder(full_path)
+ return xprotos
+
+
+def find_decls_models(path):
+ """
+ Recursively iterate a folder tree to look for any models.py file.
+ This files contain the base model for _decl generated models.
+ :param path: the root folder to start the search
+ :return: [string]
+ """
+ decls = []
+ for fn in os.listdir(path):
+ # skip hidden files and folders. plus other useless things
+ if fn.startswith(".") or fn == "venv-xos" or fn == "htmlcov":
+ continue
+ full_path = os.path.join(path, fn)
+ if fn == "models.py":
+ decls.append(full_path)
+ elif os.path.isdir(full_path):
+ decls = decls + find_decls_models(full_path)
+ return decls
+
+
+def get_service_name_from_config(path):
+ """
+ Given a service folder look for the config.yaml file and find the name
+ :param path: the root folder to start the search
+ :return: string
+ """
+ config = os.path.join(path, "xos/synchronizer/config.yaml")
+ if not os.path.isfile(config):
+ raise Exception("Config file not found at: %s" % config)
+
+ cfg_file = open(config)
+ cfg = yaml.load(cfg_file)
+ return cfg['name']
+
+
+def generate_service_models(service_dir, service_dest_dir, service_name):
+ """
+ Generate the django code starting from xProto for a given service.
+ :param service_dir: string (path to the folder)
+ :param service_name: string (name of the service)
+ :return: void
+ """
+ xprotos = find_xproto_in_folder(service_dir)
+ decls = find_decls_models(service_dir)
+ log.debug("Generating models for %s from files %s" % (service_name, ", ".join(xprotos)))
+ out_dir = os.path.join(service_dest_dir, service_name)
+ if not os.path.isdir(out_dir):
+ os.mkdir(out_dir)
+
+ args = XOSProcessorArgs(
+ output=out_dir,
+ files=xprotos,
+ target="service.xtarget",
+ write_to_file="target",
+ )
+ XOSProcessor.process(args)
+
+ security_args = XOSProcessorArgs(
+ output=out_dir,
+ target="django-security.xtarget",
+ dest_file="security.py",
+ write_to_file="single",
+ files=xprotos,
+ )
+
+ XOSProcessor.process(security_args)
+
+ init_py_filename = os.path.join(out_dir, "__init__.py")
+ if not os.path.exists(init_py_filename):
+ open(init_py_filename, "w").write("# created by dynamicbuild")
+
+ # copy over models.py files from the service
+ if len(decls) > 0:
+ for file in decls:
+ fn = os.path.basename(file)
+ src_fn = file
+ dest_fn = os.path.join(out_dir, fn)
+ log.debug("Copying models.py from %s to %s" % (src_fn, dest_fn))
+ shutil.copyfile(src_fn, dest_fn)
+
+ # copy existing migrations from the service, otherwise they won't be incremental
+ src_dir = os.path.join(service_dir, "xos", "synchronizer", "migrations")
+ if os.path.isdir(src_dir):
+ dest_dir = os.path.join(out_dir, "migrations")
+ if os.path.isdir(dest_dir):
+ shutil.rmtree(dest_dir) # empty the folder, we'll copy everything again
+ shutil.copytree(src_dir, dest_dir)
+
+
+def copy_service_migrations(service_dir, service_dest_dir, service_name):
+ """
+ Once the migrations are generated, copy them in the correct location
+ :param service_dir: string (path to the folder)
+ :param service_name: string (name of the service)
+ :return: void
+ """
+ # FIXME Django eats this message
+ log.debug("Copying %s migrations to %s" % (service_name, service_dir))
+ migration_dir = os.path.join(service_dest_dir, service_name, "migrations")
+ dest_dir = os.path.join(service_dir, "xos", "synchronizer", "migrations")
+ if os.path.isdir(dest_dir):
+ shutil.rmtree(dest_dir) # empty the folder, we'll copy everything again
+ shutil.copytree(migration_dir, dest_dir)
+
+
+def monkey_patch_migration_template():
+ import django
+ django.setup()
+
+ import django.db.migrations.writer as dj
+ dj.MIGRATION_TEMPLATE = """\
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# -*- coding: utf-8 -*-
+# Generated by Django %(version)s on %(timestamp)s
+from __future__ import unicode_literals
+
+%(imports)s
+
+class Migration(migrations.Migration):
+%(replaces_str)s%(initial_str)s
+ dependencies = [
+%(dependencies)s\
+ ]
+
+ operations = [
+%(operations)s\
+ ]
+"""
+
+# SETTING ENV
+os.environ['LOG_FILE'] = get_abs_path("django.log")
+os.environ['XOS_CONFIG_SCHEMA'] = get_abs_path("migration_cfg_schema.yaml")
+os.environ['XOS_CONFIG_FILE'] = get_abs_path("migration_cfg.yaml")
+os.environ["MIGRATIONS"] = "true"
+# this is populated in case we generate migrations for services and it's used in settings.py
+os.environ["INSTALLED_APPS"] = ""
+
+# PARAMS
+parser = argparse.ArgumentParser(description="XOS Migrations")
+required = parser.add_argument_group('required arguments')
+
+required.add_argument(
+ '-s',
+ '--service',
+ action='append',
+ required=True,
+ dest="service_names",
+ help='The name of the folder containing the service in cord/orchestration/xos_services'
+)
+
+parser.add_argument(
+ '-r',
+ '--repo',
+ default=get_abs_path("~/cord"),
+ dest="repo_root",
+ help='The location of the folder containing the CORD repo root (default to ~/cord)'
+)
+
+# FIXME this is not working with multistructlog
+parser.add_argument(
+ "-v",
+ "--verbose",
+ help="increase log verbosity",
+ action="store_true"
+)
+
+# INITIALIZING LOGGER
+Config.init()
+log = create_logger(Config().get('logging'))
+
+
+def run():
+
+ args = parser.parse_args()
+
+ print_banner(args.repo_root)
+
+ # find absolute path to the code
+ xos_path = get_abs_path(os.path.join(args.repo_root, "orchestration/xos/xos/"))
+ core_dir = get_abs_path(os.path.join(xos_path, "core/models/"))
+ service_base_dir = get_abs_path(os.path.join(xos_path, "../../xos_services/"))
+ service_dest_dir = get_abs_path(os.path.join(xos_path, "services/"))
+
+ # we need to append the xos folder to sys.path
+ original_sys_path = sys.path
+ sys.path.append(xos_path)
+
+ log.info("Services: %s" % ", ".join(args.service_names))
+
+ django_cli_args = ['xos-migrate.py', 'makemigrations']
+
+ # generate the code for each service and create a list of parameters to pass to django
+ app_list = []
+ for service in args.service_names:
+ if service == "core":
+
+ generate_core_models(core_dir)
+ django_cli_args.append("core")
+ else:
+ service_dir = os.path.join(service_base_dir, service)
+ service_name = get_service_name_from_config(service_dir)
+ generate_service_models(service_dir, service_dest_dir, service_name)
+ app_list.append("services.%s" % service_name)
+
+ django_cli_args.append(service_name)
+
+ os.environ["INSTALLED_APPS"] = ",".join(app_list)
+
+ os.environ.setdefault("DJANGO_SETTINGS_MODULE", "xos.settings")
+
+ monkey_patch_migration_template()
+
+ from django.core.management import execute_from_command_line
+
+ execute_from_command_line(django_cli_args)
+
+ # copying migrations back to the service
+ for service in args.service_names:
+ if service == "core":
+ # we don't need to copy migrations for the core
+ continue
+ else:
+ service_dir = os.path.join(service_base_dir, service)
+ service_name = get_service_name_from_config(service_dir)
+ copy_service_migrations(service_dir, service_dest_dir, service_name)
+
+ # restore orginal sys.path
+ sys.path = original_sys_path
diff --git a/lib/xos-migrate/xosmigrate/migration_cfg.yaml b/lib/xos-migrate/xosmigrate/migration_cfg.yaml
new file mode 100644
index 0000000..b3d6e58
--- /dev/null
+++ b/lib/xos-migrate/xosmigrate/migration_cfg.yaml
@@ -0,0 +1,26 @@
+
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+name: migrations
+logging:
+ version: 1
+ handlers:
+ console:
+ class: logging.StreamHandler
+ loggers:
+ 'multistructlog':
+ handlers:
+ - console
diff --git a/lib/xos-migrate/xosmigrate/migration_cfg_schema.yaml b/lib/xos-migrate/xosmigrate/migration_cfg_schema.yaml
new file mode 100644
index 0000000..3a28d64
--- /dev/null
+++ b/lib/xos-migrate/xosmigrate/migration_cfg_schema.yaml
@@ -0,0 +1,16 @@
+
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+type: any
\ No newline at end of file
diff --git a/lib/xos-synchronizer/.gitignore b/lib/xos-synchronizer/.gitignore
new file mode 100644
index 0000000..5be50bc
--- /dev/null
+++ b/lib/xos-synchronizer/.gitignore
@@ -0,0 +1,7 @@
+.noseids
+build
+XosSynchronizer.egg-info
+dist
+.coverage
+coverage.xml
+cover
\ No newline at end of file
diff --git a/scripts/setup_venv.sh b/scripts/setup_venv.sh
index 094ae0d..ea13578 100755
--- a/scripts/setup_venv.sh
+++ b/scripts/setup_venv.sh
@@ -66,5 +66,10 @@
echo "xos-synchronizer Installed"
popd
+pushd "$XOS_DIR/lib/xos-migrate"
+python ./setup.py install
+echo "xos-migrate Installed"
+popd
+
echo "XOS dev/test virtualenv created. Run 'source ${VENVDIR}/bin/activate'."
diff --git a/scripts/xos_dev_reqs.txt b/scripts/xos_dev_reqs.txt
index 86d84a0..4a4abdb 100644
--- a/scripts/xos_dev_reqs.txt
+++ b/scripts/xos_dev_reqs.txt
@@ -16,3 +16,7 @@
pykwalify==1.6.1
requests-mock==1.5.0
tosca-parser==0.9.0
+Django==1.11.11
+django-extensions==2.1.5
+djangorestframework==3.9.1
+flake8==3.7.5
diff --git a/xos/.gitignore b/xos/.gitignore
new file mode 100644
index 0000000..5da1072
--- /dev/null
+++ b/xos/.gitignore
@@ -0,0 +1 @@
+django.log
\ No newline at end of file
diff --git a/xos/core/migrations/.gitignore b/xos/core/migrations/.gitignore
deleted file mode 100644
index 68e8e0f..0000000
--- a/xos/core/migrations/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-*
-!0002_initial_data.py
\ No newline at end of file
diff --git a/xos/core/migrations/0001_initial.py b/xos/core/migrations/0001_initial.py
new file mode 100644
index 0000000..e620e2a
--- /dev/null
+++ b/xos/core/migrations/0001_initial.py
@@ -0,0 +1,2508 @@
+# -*- coding: utf-8 -*-
+# Generated by Django 1.11.18 on 2019-02-12 21:03
+
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+from __future__ import unicode_literals
+
+import core.models.xosbase_header
+from django.conf import settings
+from django.db import migrations, models
+import django.db.models.deletion
+import django.utils.timezone
+
+
+class Migration(migrations.Migration):
+
+ initial = True
+
+ dependencies = [
+ ]
+
+ operations = [
+ migrations.CreateModel(
+ name='User',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('password', models.CharField(max_length=128, verbose_name='password')),
+ ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')),
+ ('email', models.EmailField(db_index=True, max_length=255, unique=True, verbose_name=b'email address')),
+ ('username', core.models.xosbase_header.StrippedCharField(default=b'Something', max_length=255)),
+ ('firstname', core.models.xosbase_header.StrippedCharField(help_text=b"person's given name", max_length=200)),
+ ('lastname', core.models.xosbase_header.StrippedCharField(help_text=b"person's surname", max_length=200)),
+ ('phone', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'phone number contact', max_length=100, null=True)),
+ ('user_url', models.URLField(blank=True, null=True)),
+ ('public_key', models.TextField(blank=True, help_text=b'Public key string', max_length=1024, null=True)),
+ ('is_active', models.BooleanField(default=True)),
+ ('is_admin', models.BooleanField(default=False)),
+ ('is_staff', models.BooleanField(default=True)),
+ ('is_readonly', models.BooleanField(default=False)),
+ ('is_registering', models.BooleanField(default=False)),
+ ('is_appuser', models.BooleanField(default=False)),
+ ('login_page', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'send this user to a specific page on login', max_length=200, null=True)),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_status', core.models.xosbase_header.StrippedCharField(default=b'Provisioning in progress', max_length=1024)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('timezone', models.CharField(blank=True, default=b'America/New_York', max_length=100, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('policy_status', models.CharField(default=b'0 - Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(default=0, null=True)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='AddressPool_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(help_text=b'Name of this AddressPool', max_length=32, unique=True)),
+ ('addresses', models.TextField(blank=True, help_text=b'Space-separated list of available addresses', null=True)),
+ ('gateway_ip', models.CharField(help_text=b'Gateway IP address for this AddressPool', max_length=32)),
+ ('gateway_mac', models.CharField(help_text=b'Gateway MAC address for this AddressPool', max_length=32)),
+ ('cidr', models.CharField(help_text=b'Subnet for this AddressPool', max_length=32)),
+ ('inuse', models.TextField(blank=True, help_text=b'Space-separated list of inuse addresses', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Controller_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Name of the Controller', max_length=200, unique=True)),
+ ('backend_type', core.models.xosbase_header.StrippedCharField(help_text=b'Type of compute controller, e.g. EC2, OpenStack, or OpenStack version', max_length=200)),
+ ('version', core.models.xosbase_header.StrippedCharField(help_text=b'Controller version', max_length=200)),
+ ('auth_url', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Auth url for the compute controller', max_length=200, null=True)),
+ ('admin_user', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Username of an admin user at this controller', max_length=200, null=True)),
+ ('admin_password', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Password of theadmin user at this controller', max_length=200, null=True)),
+ ('admin_tenant', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Name of the tenant the admin user belongs to', max_length=200, null=True)),
+ ('domain', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Name of the domain this controller belongs to', max_length=200, null=True)),
+ ('rabbit_host', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'IP address of rabbitmq server at this controller', max_length=200, null=True)),
+ ('rabbit_user', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Username of rabbitmq server at this controller', max_length=200, null=True)),
+ ('rabbit_password', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Password of rabbitmq server at this controller', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerImages_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('glance_image_id', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Glance image id', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerNetwork_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('subnet', models.CharField(blank=True, max_length=32)),
+ ('start_ip', models.CharField(blank=True, max_length=32)),
+ ('stop_ip', models.CharField(blank=True, max_length=32)),
+ ('net_id', models.CharField(blank=True, help_text=b'Neutron network', max_length=256, null=True)),
+ ('router_id', models.CharField(blank=True, help_text=b'Neutron router id', max_length=256, null=True)),
+ ('subnet_id', models.CharField(blank=True, help_text=b'Neutron subnet id', max_length=256, null=True)),
+ ('gateway', models.CharField(blank=True, max_length=32, null=True)),
+ ('segmentation_id', models.CharField(blank=True, max_length=32, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerRole_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('role', core.models.xosbase_header.StrippedCharField(choices=[(b'admin', b'Admin')], max_length=30)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerSite_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('tenant_id', core.models.xosbase_header.StrippedCharField(blank=True, db_index=True, help_text=b'Keystone tenant id', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerSitePrivilege_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('role_id', core.models.xosbase_header.StrippedCharField(blank=True, db_index=True, help_text=b'Keystone id', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerSlice_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('tenant_id', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Keystone tenant id', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerSlicePrivilege_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('role_id', core.models.xosbase_header.StrippedCharField(blank=True, db_index=True, help_text=b'Keystone id', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ControllerUser_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('kuser_id', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Keystone user id', max_length=200, null=True)),
+ ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllerusers', to=settings.AUTH_USER_MODEL)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Deployment_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Name of the Deployment', max_length=200, unique=True)),
+ ('accessControl', models.CharField(default=b'allow all', help_text=b'Access control list that specifies which sites/users may use nodes in this deployment', max_length=200)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Flavor_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'name of this flavor, as displayed to users', max_length=32, unique=True)),
+ ('description', core.models.xosbase_header.StrippedCharField(blank=True, max_length=1024, null=True)),
+ ('flavor', core.models.xosbase_header.StrippedCharField(help_text=b'flavor string used to configure deployments', max_length=32)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Image_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(max_length=256)),
+ ('kind', models.CharField(choices=[(b'vm', b'Virtual Machine'), (b'container', b'Container')], default=b'vm', max_length=30)),
+ ('disk_format', core.models.xosbase_header.StrippedCharField(blank=True, max_length=256, null=True)),
+ ('container_format', core.models.xosbase_header.StrippedCharField(blank=True, max_length=256, null=True)),
+ ('path', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Path to image on local disk', max_length=256, null=True)),
+ ('tag', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'For Docker Images, tag of image', max_length=256, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ImageDeployments_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Instance_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('instance_id', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Nova instance id', max_length=200, null=True)),
+ ('instance_uuid', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Nova instance uuid', max_length=200, null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Instance name', max_length=200)),
+ ('instance_name', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'OpenStack generated name', max_length=200, null=True)),
+ ('ip', models.GenericIPAddressField(blank=True, help_text=b'Instance ip address', null=True)),
+ ('numberCores', models.IntegerField(default=0, help_text=b'Number of cores for instance')),
+ ('userData', models.TextField(blank=True, help_text=b'user_data passed to instance during creation', null=True)),
+ ('isolation', models.CharField(choices=[(b'vm', b'Virtual Machine'), (b'container', b'Container'), (b'container_vm', b'Container In VM')], default=b'vm', max_length=30)),
+ ('volumes', models.TextField(blank=True, help_text=b'Comma-separated list of directories to expose to parent context', null=True)),
+ ('creator', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='instances', to=settings.AUTH_USER_MODEL)),
+ ('parent', models.ForeignKey(blank=True, help_text=b'Parent Instance for containers nested inside of VMs', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='instance', to='core.Instance_decl')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='InterfaceType_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Name of this interface type', max_length=200)),
+ ('direction', core.models.xosbase_header.StrippedCharField(choices=[(b'in', b'In'), (b'out', b'Out')], help_text=b'Direction, either in or out', max_length=30)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Network_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(max_length=32, unique=True)),
+ ('subnet', models.CharField(blank=True, max_length=32)),
+ ('start_ip', models.CharField(blank=True, max_length=32)),
+ ('end_ip', models.CharField(blank=True, max_length=32)),
+ ('ports', models.CharField(blank=True, max_length=1024, null=True)),
+ ('labels', models.CharField(blank=True, max_length=1024, null=True)),
+ ('permit_all_slices', models.BooleanField(default=False)),
+ ('autoconnect', models.BooleanField(default=True, help_text=b'This network can be autoconnected to the slice that owns it')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='NetworkParameter_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('value', models.CharField(help_text=b'The value of this parameter', max_length=1024)),
+ ('content_type', core.models.xosbase_header.StrippedCharField(help_text=b'Content type id linked to this network parameter', max_length=1024)),
+ ('object_id', models.IntegerField(help_text=b'Object linked to this NetworkParameter')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='NetworkParameterType_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(db_index=True, help_text=b'The name of this parameter', max_length=128, unique=True)),
+ ('description', models.CharField(blank=True, max_length=1024)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='NetworkSlice_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='NetworkTemplate_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(max_length=32, unique=True)),
+ ('description', models.CharField(blank=True, max_length=1024, null=True)),
+ ('visibility', models.CharField(choices=[(b'public', b'public'), (b'private', b'private')], default=b'private', max_length=30)),
+ ('translation', models.CharField(choices=[(b'none', b'none'), (b'NAT', b'NAT')], default=b'none', max_length=30)),
+ ('access', models.CharField(blank=True, choices=[(None, b'None'), (b'indirect', b'Indirect'), (b'direct', b'Direct')], help_text=b'Advertise this network as a means for other slices to contact this slice', max_length=30, null=True)),
+ ('shared_network_name', models.CharField(blank=True, max_length=30, null=True)),
+ ('shared_network_id', models.CharField(blank=True, help_text=b'Quantum network', max_length=256, null=True)),
+ ('topology_kind', models.CharField(choices=[(b'bigswitch', b'BigSwitch'), (b'physical', b'Physical'), (b'custom', b'Custom')], default=b'bigswitch', max_length=30)),
+ ('controller_kind', models.CharField(blank=True, choices=[(None, b'None'), (b'onos', b'ONOS'), (b'custom', b'Custom')], max_length=30, null=True)),
+ ('vtn_kind', models.CharField(blank=True, choices=[(b'PRIVATE', b'Private'), (b'PUBLIC', b'Public'), (b'MANAGEMENT_LOCAL', b'Management Local'), (b'MANAGEMENT_HOST', b'Management Host'), (b'VSG', b'VSG'), (b'ACCESS_AGENT', b'Access Agent'), (b'FLAT', b'Flat')], default=b'PRIVATE', max_length=30, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Node_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Name of the Node', max_length=200, unique=True)),
+ ('bridgeId', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Bridge Id', max_length=200, null=True)),
+ ('dataPlaneIntf', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Dataplane Interface', max_length=200, null=True)),
+ ('dataPlaneIp', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Dataplane Ip', max_length=200, null=True)),
+ ('hostManagementIface', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Host Management Interface', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='NodeLabel_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'label name', max_length=200, unique=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Port_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('ip', models.GenericIPAddressField(blank=True, help_text=b'Instance ip address', null=True)),
+ ('port_id', models.CharField(blank=True, help_text=b'Neutron port id', max_length=256, null=True)),
+ ('mac', models.CharField(blank=True, help_text=b'MAC address associated with this port', max_length=256, null=True)),
+ ('xos_created', models.BooleanField(default=False)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Principal_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(db_index=True, help_text=b'The name of this principal', max_length=128)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Privilege_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('accessor_id', models.IntegerField()),
+ ('accessor_type', models.CharField(max_length=1024)),
+ ('controller_id', models.IntegerField(blank=True, null=True)),
+ ('object_id', models.IntegerField()),
+ ('object_type', models.CharField(max_length=1024)),
+ ('permission', models.CharField(default=b'all', max_length=1024)),
+ ('granted', models.DateTimeField(auto_now_add=True, max_length=1024)),
+ ('expires', models.DateTimeField(max_length=1024, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Role_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('role_type', core.models.xosbase_header.StrippedCharField(max_length=80)),
+ ('role', core.models.xosbase_header.StrippedCharField(blank=True, max_length=80, null=True)),
+ ('description', core.models.xosbase_header.StrippedCharField(max_length=120)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Service_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('description', models.CharField(blank=True, help_text=b'Description of Service', max_length=254, null=True)),
+ ('enabled', models.BooleanField(default=True, help_text=b'Whether or not service is Enabled')),
+ ('kind', core.models.xosbase_header.StrippedCharField(choices=[(b'generic', b'Generic'), (b'data', b'Data Plane'), (b'control', b'Control Plane'), (b'oss', b'OSS')], default=b'generic', help_text=b'Kind of service', max_length=30)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Unique name of service', max_length=30, unique=True)),
+ ('versionNumber', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Version of Service Definition', max_length=30, null=True)),
+ ('published', models.BooleanField(default=True, help_text=b'True if this service should be published in XOS')),
+ ('icon_url', core.models.xosbase_header.StrippedCharField(blank=True, max_length=1024, null=True)),
+ ('public_key', models.CharField(blank=True, help_text=b'Public key string', max_length=4096, null=True)),
+ ('private_key_fn', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Filename of private key file, located within core container', max_length=4096, null=True)),
+ ('service_specific_id', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Service-specific identifier, opaque to XOS core', max_length=30, null=True)),
+ ('service_specific_attribute', models.TextField(blank=True, help_text=b'Service-specific string attribute, opaque to XOS core', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn, core.models.xosbase_header.AttributeMixin),
+ ),
+ migrations.CreateModel(
+ name='ServiceAttribute_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(help_text=b'Attribute Name', max_length=128)),
+ ('value', models.TextField(help_text=b'Attribute Value')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ServiceDependency_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('connect_method', models.CharField(choices=[(b'none', b'None'), (b'private', b'Private'), (b'public', b'Public')], default=b'none', help_text=b'method to connect the two services', max_length=30)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ServiceGraphConstraint_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('constraints', core.models.xosbase_header.StrippedCharField(help_text=b'A composite array defining positions, eg [volt, vsg, [address_manager, vrouter]]', max_length=1024)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ServiceInstance_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Name of ServiceInstance', max_length=200, null=True)),
+ ('service_specific_id', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Service-specific identifier, opaque to the XOS core', max_length=30, null=True)),
+ ('service_specific_attribute', models.TextField(blank=True, help_text=b'Service-specific text attribute, opaque to the XOS core', null=True)),
+ ('link_deleted_count', models.IntegerField(blank=True, default=0, help_text=b'Incremented each time a provided_link is deleted from this ServiceInstance', null=True)),
+ ('master_serviceinstance', models.ForeignKey(blank=True, help_text=b'The master service instance that set this service instance up', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='child_serviceinstances', to='core.ServiceInstance_decl')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn, core.models.xosbase_header.AttributeMixin),
+ ),
+ migrations.CreateModel(
+ name='ServiceInstanceAttribute_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(help_text=b'Attribute Name', max_length=128)),
+ ('value', models.TextField(help_text=b'Attribute Value')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ServiceInstanceLink_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ServiceInterface_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='ServicePort_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(help_text=b'Unique service port name', max_length=128)),
+ ('external_port', models.IntegerField(help_text=b'external port number')),
+ ('internal_port', models.IntegerField(help_text=b'internal port number')),
+ ('protocol', models.CharField(default=b'TCP', help_text=b'Protocol', max_length=32)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Site_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Name for this Site', max_length=200, unique=True)),
+ ('site_url', models.URLField(blank=True, help_text=b"Site's Home URL Page", max_length=512, null=True)),
+ ('enabled', models.BooleanField(default=True, help_text=b'Status for this Site')),
+ ('hosts_nodes', models.BooleanField(default=True, help_text=b'Indicates whether or not the site host nodes')),
+ ('hosts_users', models.BooleanField(default=True, help_text=b'Indicates whether or not the site manages user accounts')),
+ ('longitude', models.FloatField(blank=True, null=True)),
+ ('latitude', models.FloatField(blank=True, null=True)),
+ ('login_base', core.models.xosbase_header.StrippedCharField(help_text=b'Prefix for Slices associated with this Site', max_length=50)),
+ ('is_public', models.BooleanField(default=True, help_text=b'Indicates the visibility of this site to other members')),
+ ('abbreviated_name', core.models.xosbase_header.StrippedCharField(max_length=80)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='SiteDeployment_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('availability_zone', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'OpenStack availability zone', max_length=200, null=True)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='SitePrivilege_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='siteprivileges', to=settings.AUTH_USER_MODEL)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='SiteRole_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('role', core.models.xosbase_header.StrippedCharField(choices=[(b'admin', b'Admin'), (b'pi', b'PI'), (b'tech', b'Tech'), (b'billing', b'Billing')], max_length=30)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Slice_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'The Name of the Slice', max_length=80, unique=True)),
+ ('enabled', models.BooleanField(default=True, help_text=b'Status for this Slice')),
+ ('description', models.CharField(blank=True, help_text=b'High level description of the slice and expected activities', max_length=1024)),
+ ('max_instances', models.IntegerField(default=10)),
+ ('network', models.CharField(blank=True, choices=[(None, b'Default'), (b'host', b'Host'), (b'bridged', b'Bridged'), (b'noauto', b'No Automatic Networks')], max_length=256, null=True)),
+ ('exposed_ports', models.CharField(blank=True, max_length=256, null=True)),
+ ('mount_data_sets', core.models.xosbase_header.StrippedCharField(blank=True, default=b'GenBank', max_length=256, null=True)),
+ ('default_isolation', models.CharField(choices=[(b'vm', b'Virtual Machine'), (b'container', b'Container'), (b'container_vm', b'Container In VM')], default=b'vm', max_length=30)),
+ ('controller_replica_count', models.IntegerField(default=0, help_text=b'Replica count, controller-dependent')),
+ ('controller_kind', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Type of controller, vim-dependent', max_length=256, null=True)),
+ ('creator', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to=settings.AUTH_USER_MODEL)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='SlicePrivilege_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sliceprivileges', to=settings.AUTH_USER_MODEL)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='SliceRole_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('role', core.models.xosbase_header.StrippedCharField(choices=[(b'admin', b'Admin'), (b'default', b'Default'), (b'access', b'Access')], max_length=30)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='Tag_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(db_index=True, help_text=b'The name of this tag', max_length=128)),
+ ('value', core.models.xosbase_header.StrippedCharField(help_text=b'The value of this tag', max_length=1024)),
+ ('content_type', core.models.xosbase_header.StrippedCharField(help_text=b'Content type id linked to this tag', max_length=1024)),
+ ('object_id', models.IntegerField(help_text=b'Object linked to this tag')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='TrustDomain_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', models.CharField(db_index=True, help_text=b'Name of this trust domain', max_length=255)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='XOSCore_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(default=b'XOS', help_text=b'Name of XOS', max_length=200, unique=b'True')),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.CreateModel(
+ name='XOSGuiExtension_decl',
+ fields=[
+ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
+ ('created', models.DateTimeField(auto_now_add=True, help_text=b'Time this model was created')),
+ ('updated', models.DateTimeField(default=django.utils.timezone.now, help_text=b'Time this model was changed by a non-synchronizer')),
+ ('enacted', models.DateTimeField(blank=True, default=None, help_text=b'When synced, set to the timestamp of the data that was synced', null=True)),
+ ('policed', models.DateTimeField(blank=True, default=None, help_text=b'When policed, set to the timestamp of the data that was policed', null=True)),
+ ('backend_register', models.CharField(blank=True, default=b'{}', max_length=1024, null=True)),
+ ('backend_need_delete', models.BooleanField(default=False)),
+ ('backend_need_reap', models.BooleanField(default=False)),
+ ('backend_status', models.CharField(default=b'Provisioning in progress', max_length=1024, null=True)),
+ ('backend_code', models.IntegerField(default=0)),
+ ('deleted', models.BooleanField(default=False)),
+ ('write_protect', models.BooleanField(default=False)),
+ ('lazy_blocked', models.BooleanField(default=False)),
+ ('no_sync', models.BooleanField(default=False)),
+ ('no_policy', models.BooleanField(default=False)),
+ ('policy_status', models.CharField(blank=True, default=b'Policy in process', max_length=1024, null=True)),
+ ('policy_code', models.IntegerField(blank=True, default=0, null=True)),
+ ('leaf_model_name', models.CharField(help_text=b'The most specialized model in this chain of inheritance, often defined by a service developer', max_length=1024)),
+ ('backend_need_delete_policy', models.BooleanField(default=False, help_text=b'True if delete model_policy must be run before object can be reaped')),
+ ('xos_managed', models.BooleanField(default=True, help_text=b'True if xos is responsible for creating/deleting this object')),
+ ('backend_handle', models.CharField(blank=True, help_text=b'Handle used by the backend to track this object', max_length=1024, null=True)),
+ ('changed_by_step', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a sync step', null=True)),
+ ('changed_by_policy', models.DateTimeField(blank=True, default=None, help_text=b'Time this model was changed by a model policy', null=True)),
+ ('name', core.models.xosbase_header.StrippedCharField(help_text=b'Name of the GUI Extensions', max_length=200, unique=True)),
+ ('files', core.models.xosbase_header.StrippedCharField(help_text=b'List of comma separated file composing the view', max_length=1024)),
+ ],
+ bases=(models.Model, core.models.xosbase_header.PlModelMixIn),
+ ),
+ migrations.AlterUniqueTogether(
+ name='interfacetype_decl',
+ unique_together=set([('direction', 'name')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='image_decl',
+ unique_together=set([('tag', 'name')]),
+ ),
+ migrations.CreateModel(
+ name='AddressPool',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.addresspool_decl',),
+ ),
+ migrations.CreateModel(
+ name='Controller',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controller_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerImages',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllerimages_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerNetwork',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllernetwork_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerRole',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllerrole_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerSite',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllersite_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerSitePrivilege',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllersiteprivilege_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerSlice',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllerslice_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerSlicePrivilege',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controllersliceprivilege_decl',),
+ ),
+ migrations.CreateModel(
+ name='ControllerUser',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.controlleruser_decl',),
+ ),
+ migrations.CreateModel(
+ name='Deployment',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.deployment_decl',),
+ ),
+ migrations.CreateModel(
+ name='Flavor',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.flavor_decl',),
+ ),
+ migrations.CreateModel(
+ name='Image',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.image_decl',),
+ ),
+ migrations.CreateModel(
+ name='ImageDeployments',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.imagedeployments_decl',),
+ ),
+ migrations.CreateModel(
+ name='Instance',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.instance_decl',),
+ ),
+ migrations.CreateModel(
+ name='InterfaceType',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.interfacetype_decl',),
+ ),
+ migrations.CreateModel(
+ name='Network',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.network_decl',),
+ ),
+ migrations.CreateModel(
+ name='NetworkParameter',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.networkparameter_decl',),
+ ),
+ migrations.CreateModel(
+ name='NetworkParameterType',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.networkparametertype_decl',),
+ ),
+ migrations.CreateModel(
+ name='NetworkSlice',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.networkslice_decl',),
+ ),
+ migrations.CreateModel(
+ name='NetworkTemplate',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.networktemplate_decl',),
+ ),
+ migrations.CreateModel(
+ name='Node',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.node_decl',),
+ ),
+ migrations.CreateModel(
+ name='NodeLabel',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.nodelabel_decl',),
+ ),
+ migrations.CreateModel(
+ name='Port',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.port_decl',),
+ ),
+ migrations.CreateModel(
+ name='Principal',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.principal_decl',),
+ ),
+ migrations.CreateModel(
+ name='Privilege',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.privilege_decl',),
+ ),
+ migrations.CreateModel(
+ name='Role',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.role_decl',),
+ ),
+ migrations.CreateModel(
+ name='Service',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.service_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceAttribute',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.serviceattribute_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceDependency',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.servicedependency_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceGraphConstraint',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.servicegraphconstraint_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceInstance',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.serviceinstance_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceInstanceAttribute',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.serviceinstanceattribute_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceInstanceLink',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.serviceinstancelink_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServiceInterface',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.serviceinterface_decl',),
+ ),
+ migrations.CreateModel(
+ name='ServicePort',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.serviceport_decl',),
+ ),
+ migrations.CreateModel(
+ name='Site',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.site_decl',),
+ ),
+ migrations.CreateModel(
+ name='SiteDeployment',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.sitedeployment_decl',),
+ ),
+ migrations.CreateModel(
+ name='SitePrivilege',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.siteprivilege_decl',),
+ ),
+ migrations.CreateModel(
+ name='SiteRole',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.siterole_decl',),
+ ),
+ migrations.CreateModel(
+ name='Slice',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.slice_decl',),
+ ),
+ migrations.CreateModel(
+ name='SlicePrivilege',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.sliceprivilege_decl',),
+ ),
+ migrations.CreateModel(
+ name='SliceRole',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.slicerole_decl',),
+ ),
+ migrations.CreateModel(
+ name='Tag',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.tag_decl',),
+ ),
+ migrations.CreateModel(
+ name='TrustDomain',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.trustdomain_decl',),
+ ),
+ migrations.CreateModel(
+ name='XOSCore',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.xoscore_decl',),
+ ),
+ migrations.CreateModel(
+ name='XOSGuiExtension',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.xosguiextension_decl',),
+ ),
+ migrations.CreateModel(
+ name='ComputeServiceInstance_decl',
+ fields=[
+ ('serviceinstance_decl_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='core.ServiceInstance_decl')),
+ ('image', models.ForeignKey(help_text=b'Image used to instantiate this ServiceInstance', on_delete=django.db.models.deletion.CASCADE, related_name='computeserviceinstances', to='core.Image')),
+ ('slice', models.ForeignKey(help_text=b'Slice that controls this ServiceInstance', on_delete=django.db.models.deletion.CASCADE, related_name='computeserviceinstances', to='core.Slice')),
+ ],
+ bases=('core.serviceinstance',),
+ ),
+ migrations.CreateModel(
+ name='TenantWithContainer_decl',
+ fields=[
+ ('serviceinstance_decl_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='core.ServiceInstance_decl')),
+ ('external_hostname', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'External host name', max_length=30, null=True)),
+ ('external_container', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'External host name', max_length=30, null=True)),
+ ('node_label', core.models.xosbase_header.StrippedCharField(blank=True, help_text=b'Node constraint', max_length=30, null=True)),
+ ],
+ bases=('core.serviceinstance',),
+ ),
+ migrations.AddField(
+ model_name='trustdomain_decl',
+ name='owner',
+ field=models.ForeignKey(help_text=b'Service partioned by this trust domain', on_delete=django.db.models.deletion.CASCADE, related_name='owned_trust_domains', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='tag_decl',
+ name='service',
+ field=models.ForeignKey(help_text=b'The Service this Tag is associated with', on_delete=django.db.models.deletion.CASCADE, related_name='tags', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='sliceprivilege_decl',
+ name='role',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sliceprivileges', to='core.SliceRole'),
+ ),
+ migrations.AddField(
+ model_name='sliceprivilege_decl',
+ name='slice',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sliceprivileges', to='core.Slice'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='default_flavor',
+ field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.Flavor'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='default_image',
+ field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.Image'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='default_node',
+ field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.Node'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='principal',
+ field=models.ForeignKey(blank=True, help_text=b'Principal this slice may use to interact with other components', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.Principal'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='service',
+ field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='site',
+ field=models.ForeignKey(help_text=b'The Site this Slice belongs to', on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.Site'),
+ ),
+ migrations.AddField(
+ model_name='slice_decl',
+ name='trust_domain',
+ field=models.ForeignKey(blank=True, help_text=b'Trust domain this slice resides in', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='slices', to='core.TrustDomain'),
+ ),
+ migrations.AddField(
+ model_name='siteprivilege_decl',
+ name='role',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='siteprivileges', to='core.SiteRole'),
+ ),
+ migrations.AddField(
+ model_name='siteprivilege_decl',
+ name='site',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='siteprivileges', to='core.Site'),
+ ),
+ migrations.AddField(
+ model_name='sitedeployment_decl',
+ name='controller',
+ field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='sitedeployments', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='sitedeployment_decl',
+ name='deployment',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sitedeployments', to='core.Deployment'),
+ ),
+ migrations.AddField(
+ model_name='sitedeployment_decl',
+ name='site',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sitedeployments', to='core.Site'),
+ ),
+ migrations.AddField(
+ model_name='serviceport_decl',
+ name='service',
+ field=models.ForeignKey(help_text=b'The Service this ServicePort is associated with', on_delete=django.db.models.deletion.CASCADE, related_name='serviceports', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='serviceinterface_decl',
+ name='interface_type',
+ field=models.ForeignKey(help_text=b'Interface type that describes this interface', on_delete=django.db.models.deletion.CASCADE, related_name='service_interfaces', to='core.InterfaceType'),
+ ),
+ migrations.AddField(
+ model_name='serviceinterface_decl',
+ name='service',
+ field=models.ForeignKey(help_text=b'Service that this ServiceInterface is associated with', on_delete=django.db.models.deletion.CASCADE, related_name='service_interfaces', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstancelink_decl',
+ name='provider_service_instance',
+ field=models.ForeignKey(help_text=b'Eastbound serviceinstance of this link', on_delete=django.db.models.deletion.CASCADE, related_name='provided_links', to='core.ServiceInstance'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstancelink_decl',
+ name='provider_service_interface',
+ field=models.ForeignKey(blank=True, help_text=b'Interface descrption of the eastbound linkage point', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='provided_links', to='core.ServiceInterface'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstancelink_decl',
+ name='subscriber_network',
+ field=models.ForeignKey(blank=True, help_text=b'Alternative to subscriber_service_instance, if a Network model is the subscriber instead of a ServiceInstance', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='subscribed_links', to='core.Network'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstancelink_decl',
+ name='subscriber_service',
+ field=models.ForeignKey(blank=True, help_text=b'Interface description of the westbound linkage point', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='subscribed_links', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstancelink_decl',
+ name='subscriber_service_instance',
+ field=models.ForeignKey(blank=True, help_text=b'Westbound ServiceInstance of this link', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='subscribed_links', to='core.ServiceInstance'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstanceattribute_decl',
+ name='service_instance',
+ field=models.ForeignKey(help_text=b'The Tenant this attribute is associated with', on_delete=django.db.models.deletion.CASCADE, related_name='service_instance_attributes', to='core.ServiceInstance'),
+ ),
+ migrations.AddField(
+ model_name='serviceinstance_decl',
+ name='owner',
+ field=models.ForeignKey(help_text=b'The Service that owns this ServiceInstance', on_delete=django.db.models.deletion.CASCADE, related_name='service_instances', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='servicedependency_decl',
+ name='provider_service',
+ field=models.ForeignKey(help_text=b'The service that provides this dependency', on_delete=django.db.models.deletion.CASCADE, related_name='provided_dependencies', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='servicedependency_decl',
+ name='subscriber_service',
+ field=models.ForeignKey(help_text=b'The services that subscribes to this dependency', on_delete=django.db.models.deletion.CASCADE, related_name='subscribed_dependencies', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='serviceattribute_decl',
+ name='service',
+ field=models.ForeignKey(help_text=b'The Service this attribute is associated with', on_delete=django.db.models.deletion.CASCADE, related_name='serviceattributes', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='principal_decl',
+ name='trust_domain',
+ field=models.ForeignKey(help_text=b'Trust domain this principal resides in', on_delete=django.db.models.deletion.CASCADE, related_name='principals', to='core.TrustDomain'),
+ ),
+ migrations.AddField(
+ model_name='port_decl',
+ name='instance',
+ field=models.ForeignKey(blank=True, help_text=b'Instance bound to this port', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='ports', to='core.Instance'),
+ ),
+ migrations.AddField(
+ model_name='port_decl',
+ name='network',
+ field=models.ForeignKey(help_text=b'Network bound to this port', on_delete=django.db.models.deletion.CASCADE, related_name='links', to='core.Network'),
+ ),
+ migrations.AddField(
+ model_name='port_decl',
+ name='service_instance',
+ field=models.ForeignKey(blank=True, help_text=b'ServiceInstance bound to this port', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='ports', to='core.ServiceInstance'),
+ ),
+ migrations.AddField(
+ model_name='nodelabel_decl',
+ name='node',
+ field=models.ManyToManyField(related_name='nodelabels', to='core.Node'),
+ ),
+ migrations.AddField(
+ model_name='node_decl',
+ name='site_deployment',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='nodes', to='core.SiteDeployment'),
+ ),
+ migrations.AddField(
+ model_name='networkslice_decl',
+ name='network',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='networkslices', to='core.Network'),
+ ),
+ migrations.AddField(
+ model_name='networkslice_decl',
+ name='slice',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='networkslices', to='core.Slice'),
+ ),
+ migrations.AddField(
+ model_name='networkparameter_decl',
+ name='parameter',
+ field=models.ForeignKey(help_text=b'The type of the parameter', on_delete=django.db.models.deletion.CASCADE, related_name='networkparameters', to='core.NetworkParameterType'),
+ ),
+ migrations.AddField(
+ model_name='network_decl',
+ name='owner',
+ field=models.ForeignKey(help_text=b'Slice that owns control of this Network', on_delete=django.db.models.deletion.CASCADE, related_name='ownedNetworks', to='core.Slice'),
+ ),
+ migrations.AddField(
+ model_name='network_decl',
+ name='permitted_slices',
+ field=models.ManyToManyField(related_name='availableNetworks', to='core.Slice'),
+ ),
+ migrations.AddField(
+ model_name='network_decl',
+ name='template',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='network', to='core.NetworkTemplate'),
+ ),
+ migrations.AddField(
+ model_name='instance_decl',
+ name='deployment',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='instance_deployment', to='core.Deployment'),
+ ),
+ migrations.AddField(
+ model_name='instance_decl',
+ name='flavor',
+ field=models.ForeignKey(help_text=b'Flavor of this instance', on_delete=django.db.models.deletion.CASCADE, related_name='instance', to='core.Flavor'),
+ ),
+ migrations.AddField(
+ model_name='instance_decl',
+ name='image',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='instances', to='core.Image'),
+ ),
+ migrations.AddField(
+ model_name='instance_decl',
+ name='node',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='instances', to='core.Node'),
+ ),
+ migrations.AddField(
+ model_name='instance_decl',
+ name='slice',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='instances', to='core.Slice'),
+ ),
+ migrations.AddField(
+ model_name='imagedeployments_decl',
+ name='deployment',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='imagedeployments', to='core.Deployment'),
+ ),
+ migrations.AddField(
+ model_name='imagedeployments_decl',
+ name='image',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='imagedeployments', to='core.Image'),
+ ),
+ migrations.AddField(
+ model_name='controlleruser_decl',
+ name='controller',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllersusers', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllersliceprivilege_decl',
+ name='controller',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllersliceprivileges', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllersliceprivilege_decl',
+ name='slice_privilege',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllersliceprivileges', to='core.SlicePrivilege'),
+ ),
+ migrations.AddField(
+ model_name='controllerslice_decl',
+ name='controller',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllerslices', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllerslice_decl',
+ name='slice',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllerslices', to='core.Slice'),
+ ),
+ migrations.AddField(
+ model_name='controllersiteprivilege_decl',
+ name='controller',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllersiteprivileges', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllersiteprivilege_decl',
+ name='site_privilege',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllersiteprivileges', to='core.SitePrivilege'),
+ ),
+ migrations.AddField(
+ model_name='controllersite_decl',
+ name='controller',
+ field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='controllersite', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllersite_decl',
+ name='site',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllersite', to='core.Site'),
+ ),
+ migrations.AddField(
+ model_name='controllernetwork_decl',
+ name='controller',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllernetworks', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllernetwork_decl',
+ name='network',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllernetworks', to='core.Network'),
+ ),
+ migrations.AddField(
+ model_name='controllerimages_decl',
+ name='controller',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllerimages', to='core.Controller'),
+ ),
+ migrations.AddField(
+ model_name='controllerimages_decl',
+ name='image',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllerimages', to='core.Image'),
+ ),
+ migrations.AddField(
+ model_name='controller_decl',
+ name='deployment',
+ field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='controllerdeployments', to='core.Deployment'),
+ ),
+ migrations.AddField(
+ model_name='addresspool_decl',
+ name='service',
+ field=models.ForeignKey(blank=True, help_text=b'Service this AddressPool belongs to', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='addresspools', to='core.Service'),
+ ),
+ migrations.AddField(
+ model_name='user',
+ name='site',
+ field=models.ForeignKey(help_text=b'Site this user will be homed too', on_delete=django.db.models.deletion.CASCADE, related_name='users', to='core.Site'),
+ ),
+ migrations.AddField(
+ model_name='tenantwithcontainer_decl',
+ name='creator',
+ field=models.ForeignKey(blank=True, help_text=b'Creator of this Tenant', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='+', to=settings.AUTH_USER_MODEL),
+ ),
+ migrations.AddField(
+ model_name='tenantwithcontainer_decl',
+ name='instance',
+ field=models.ForeignKey(blank=True, help_text=b'Instance used by this Tenant', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='+', to='core.Instance'),
+ ),
+ migrations.AlterUniqueTogether(
+ name='sliceprivilege_decl',
+ unique_together=set([('slice', 'role', 'user')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='sitedeployment_decl',
+ unique_together=set([('controller', 'site', 'deployment')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='serviceinstanceattribute_decl',
+ unique_together=set([('service_instance', 'name')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='serviceattribute_decl',
+ unique_together=set([('name', 'service')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='port_decl',
+ unique_together=set([('instance', 'network')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='networkslice_decl',
+ unique_together=set([('slice', 'network')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='imagedeployments_decl',
+ unique_together=set([('image', 'deployment')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controlleruser_decl',
+ unique_together=set([('controller', 'user')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controllersliceprivilege_decl',
+ unique_together=set([('controller', 'slice_privilege')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controllerslice_decl',
+ unique_together=set([('controller', 'slice')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controllersiteprivilege_decl',
+ unique_together=set([('controller', 'site_privilege', 'role_id')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controllersite_decl',
+ unique_together=set([('controller', 'site')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controllernetwork_decl',
+ unique_together=set([('controller', 'network')]),
+ ),
+ migrations.AlterUniqueTogether(
+ name='controllerimages_decl',
+ unique_together=set([('controller', 'image')]),
+ ),
+ migrations.CreateModel(
+ name='ComputeServiceInstance',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.computeserviceinstance_decl',),
+ ),
+ migrations.CreateModel(
+ name='TenantWithContainer',
+ fields=[
+ ],
+ options={
+ 'proxy': True,
+ 'indexes': [],
+ },
+ bases=('core.tenantwithcontainer_decl',),
+ ),
+ ]
diff --git a/xos/core/migrations/__init__.py b/xos/core/migrations/__init__.py
new file mode 100644
index 0000000..eb28b96
--- /dev/null
+++ b/xos/core/migrations/__init__.py
@@ -0,0 +1,13 @@
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
\ No newline at end of file
diff --git a/xos/services/.gitignore b/xos/services/.gitignore
new file mode 100644
index 0000000..a0fb9c7
--- /dev/null
+++ b/xos/services/.gitignore
@@ -0,0 +1,4 @@
+*
+!.gitignore
+!.__init__.py
+!README.md
\ No newline at end of file
diff --git a/xos/xos/settings.py b/xos/xos/settings.py
index d8e4314..c9ec5f7 100644
--- a/xos/xos/settings.py
+++ b/xos/xos/settings.py
@@ -45,15 +45,22 @@
MANAGERS = ADMINS
-DATABASES = {
- "default": {
- "ENGINE": "django.db.backends.postgresql_psycopg2",
- "NAME": Config.get("database.name"),
- "USER": Config.get("database.username"),
- "PASSWORD": Config.get("database.password"),
- "HOST": "xos-db",
- "PORT": 5432,
+DB = {
+ "ENGINE": "django.db.backends.postgresql_psycopg2",
+ "NAME": Config.get("database.name"),
+ "USER": Config.get("database.username"),
+ "PASSWORD": Config.get("database.password"),
+ "HOST": "xos-db",
+ "PORT": 5432,
+}
+
+if "MIGRATIONS" in os.environ and os.environ["MIGRATIONS"] == "true":
+ DB = {
+ 'ENGINE': 'django.db.backends.dummy',
}
+
+DATABASES = {
+ 'default': DB
}
AUTH_USER_MODEL = "core.User"
@@ -180,11 +187,21 @@
if line:
INSTALLED_APPS = list(INSTALLED_APPS) + [line]
+# add services that needs to be migrated to INSTALLED_APPS
+# this is used by xos-migrate.py
+if "INSTALLED_APPS" in os.environ:
+ apps = os.environ["INSTALLED_APPS"].split(',')
+ for app in apps:
+ INSTALLED_APPS = list(INSTALLED_APPS) + [app]
+
# A sample logging configuration. The only tangible logging
# performed by this configuration is to send an email to
# the site admins on every HTTP 500 error when DEBUG=False.
# See http://docs.djangoproject.com/en/dev/topics/logging for
# more details on how to customize your logging configuration.
+LOG_FILE = "/var/log/django_debug.log"
+if "LOG_FILE" in os.environ:
+ LOG_FILE = os.environ["LOG_FILE"]
LOGGING = {
"version": 1,
"disable_existing_loggers": False,
@@ -193,7 +210,7 @@
"file": {
"level": "DEBUG",
"class": "logging.FileHandler",
- "filename": "/var/log/django_debug.log",
+ "filename": LOG_FILE,
},
"mail_admins": {
"level": "ERROR",