34 lines
688 B
Python
34 lines
688 B
Python
import pulumi_openstack as os
|
|
|
|
key_pair = os.compute.Keypair(
|
|
'default',
|
|
name='dustin--rosalina',
|
|
public_key='ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJsL5fSylmiJmBtW0DH/viAAmtU2E/2M17GPvysiyRs+',
|
|
)
|
|
|
|
flavor = os.compute.get_flavor(
|
|
vcpus=1,
|
|
ram=1024,
|
|
)
|
|
|
|
image = os.images.get_image(
|
|
name='AlmaLinux-9-amd64',
|
|
)
|
|
|
|
instance = os.compute.Instance(
|
|
'vps',
|
|
flavor_id=flavor.id,
|
|
image_id=image.id,
|
|
key_pair=key_pair.id,
|
|
networks=[
|
|
{'name': 'Internet-01'},
|
|
],
|
|
metadata={
|
|
'os_distro': 'alma', # Sets the icon in the HostVDS Control Panel
|
|
'groups': 'remote-blackbox',
|
|
},
|
|
security_groups=[
|
|
'allow_all',
|
|
],
|
|
)
|