-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.py
More file actions
27 lines (22 loc) · 786 Bytes
/
example.py
File metadata and controls
27 lines (22 loc) · 786 Bytes
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
from mushroomcloud import SecurityGroup
x = SecurityGroup("myName", VpcId="a", Description="b")
class TwoSecurityGroups:
def __init__(self, name, a, b):
self.sg1 = SecurityGroup("SG1", VpcId = a)
self.sg2 = SecurityGroup("SG2", VpcId = b)
class TwoWrapper:
def __init__(self, name):
self.two = TwoSecurityGroups("Two", 1, 2)
y = TwoWrapper("Wrapper")
## How do things execute at the end?
# push function that plans on global thing
# for each element,
# compare with statefile
# write to global thing
# if no ID (does not exist)
# - create function
# - update state
# - update function
# - destroy/create function
# - destroy function (hard)
# execute function that plans on global thing