forked from nutanix/calm-dsl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
demo_project.py
36 lines (29 loc) · 1.09 KB
/
demo_project.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
from calm.dsl.builtins import Project
from calm.dsl.builtins import Provider, Ref
NTNX_ACCOUNT_NAME = "NTNX_LOCAL_AZ"
NTNX_SUBNET = "vlan.0"
NTNX_SUBNET_CLUSTER = "calmdev1"
AWS_ACCOUNT_NAME = "aws_account"
AZURE_ACCOUNT_NAME = "azure_account"
GCP_ACCOUNT_NAME = "gcp_account"
VMWARE_ACCOUNT_NAME = "vmware_account"
K8S_ACCOUNT_NAME = "k8s_account"
USER = "sspuser1@systest.nutanix.com"
VCPUS = 1
STORAGE = 2 # GiB
MEMORY = 1 # GiB
class TestDslDemoProject(Project):
"""Sample DSL Project"""
providers = [
Provider.Ntnx(
account=Ref.Account(NTNX_ACCOUNT_NAME),
subnets=[Ref.Subnet(name=NTNX_SUBNET, cluster=NTNX_SUBNET_CLUSTER)],
),
Provider.Aws(account=Ref.Account(AWS_ACCOUNT_NAME)),
Provider.Azure(account=Ref.Account(AZURE_ACCOUNT_NAME)),
Provider.Gcp(account=Ref.Account(GCP_ACCOUNT_NAME)),
Provider.Vmware(account=Ref.Account(VMWARE_ACCOUNT_NAME)),
Provider.K8s(account=Ref.Account(K8S_ACCOUNT_NAME)),
]
users = [Ref.User(name=USER)]
quotas = {"vcpus": VCPUS, "storage": STORAGE, "memory": MEMORY}