blob: 5b087880dd5bf49912cb49223df3313bac6cff56 [file] [log] [blame]
gio36b23b32024-08-25 12:20:54 +04001input: {
2 name: string @name(Hostname)
3 username: string @name(Username)
4 authKey: string @name(Auth Key) @role(VPNAuthKey) @usernameField(username)
5 cpuCores: int | *1 @name(CPU Cores)
6 memory: string | *"2Gi" @name(Memory)
7}
8
9name: "Virutal Machine"
10namespace: "app-vm"
11readme: "Virtual Machine"
12description: "Virtual Machine"
13icon: """
gio7fbd4ad2024-08-27 10:06:39 +040014 <svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 2048 2048"><path fill="currentColor" d="M1280 384H640V256h640zm0 1024H640v-128h640zm0 256H640v-128h640zM1408 0q27 0 50 10t40 27t28 41t10 50v1792H384V128q0-27 10-50t27-40t41-28t50-10zm0 128H512v1664h896z"/></svg>"""
gio36b23b32024-08-25 12:20:54 +040015
gio7fbd4ad2024-08-27 10:06:39 +040016out: {
17 vm: {
18 "\(input.name)": {
19 username: input.username
20 domain: global.domain
gio36b23b32024-08-25 12:20:54 +040021 cpuCores: input.cpuCores
22 memory: input.memory
gio7fbd4ad2024-08-27 10:06:39 +040023 vpn: {
24 enabled: true
25 loginServer: "https://headscale.\(global.domain)"
26 authKey: input.authKey
gio36b23b32024-08-25 12:20:54 +040027 }
gio36b23b32024-08-25 12:20:54 +040028 }
29 }
30}