Feature 10239: Distributed VCA
- Add vca_id in all calls that invoke libjuju. This is for being able to
talk to the default VCA or the VCA associated to the VIM
- Add store.py: Abstraction to talk to the database.
- DBMongoStore: Use the db from common to talk to the database
- MotorStore: Use motor, an asynchronous mongodb client to talk to the
database
- Add vca/connection.py: Represents the data needed to connect the VCA
- Add EnvironConfig in config.py: Class to get the environment config,
and avoid LCM from passing that
Change-Id: I28625e0c56ce408114022c83d4b7cacbb649434c
Signed-off-by: David Garcia <david.garcia@canonical.com>
diff --git a/n2vc/vca/cloud.py b/n2vc/vca/cloud.py
new file mode 100644
index 0000000..970fd93
--- /dev/null
+++ b/n2vc/vca/cloud.py
@@ -0,0 +1,25 @@
+# Copyright 2021 Canonical Ltd.
+#
+# 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.
+
+
+class Cloud:
+ def __init__(self, name: str, credential_name: str):
+ """
+ Constructor
+
+ :param: name: Name of the Cloud
+ :param: credential_name: Credential name for the Cloud
+ """
+ self.name = name
+ self.credential_name = credential_name