Piccoli aggiustamenti ai template per proxmox vm.

This commit is contained in:
Emiliano Vavassori 2024-04-19 01:05:26 +02:00
parent 3d0dce28c2
commit ab749f7e11
2 changed files with 10 additions and 10 deletions

View File

@ -14,12 +14,10 @@ i.close()
config = pulumi.Config()
provider = proxmox.Provider("proxmoxve",
virtual_environment = {
"endpoint": input_['pve']['url'],
"insecure": input_['pve']['insecure'],
"username": input_['pve']['username'],
"password": config.require_secret("password")
}
endpoint=input_['pve']['url'],
insecure=input_['pve']['insecure'],
username=input_['pve']['username'],
password=config.require_secret("password")
)
vm_name = input_['vm']['name']
@ -75,7 +73,8 @@ vm = proxmox.vm.VirtualMachine("vm",
)
),
opts = pulumi.ResourceOptions(
provider = provider
provider = provider,
custom_timeouts=pulumi.CustomTimeouts(create="3m")
)
)

View File

@ -1,9 +1,9 @@
"""A ProxmoxVE VM template with Python"""
import yaml
from dotmap import DotMap
import pulumi
import pulumi_proxmoxve as proxmox
import yaml
from dotmap import DotMap
conf = DotMap(yaml.safe_load(open("input.yaml").read()))
config = pulumi.Config()
@ -63,7 +63,8 @@ vm = proxmox.vm.VirtualMachine(conf.vm.name,
)
),
opts = pulumi.ResourceOptions(
provider = provider
provider = provider,
custom_timeouts=pulumi.CustomTimeouts(create="3m")
)
)