-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprovider.yaml.tpl
More file actions
172 lines (172 loc) · 4.21 KB
/
provider.yaml.tpl
File metadata and controls
172 lines (172 loc) · 4.21 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
name: stackit
version: {{ .Env.VERSION }}
description: |-
DevPod on STACKIT
icon: https://github.com/stackitcloud/devpod-provider-stackit/blob/80d9a236cd309baf50e756480c4c00689f83b001/assets/stackit.png
optionGroups:
- options:
- AGENT_PATH
- INACTIVITY_TIMEOUT
- INJECT_DOCKER_CREDENTIALS
- INJECT_GIT_CREDENTIALS
name: "Agent options"
defaultVisible: false
- options:
- STACKIT_PROJECT_ID
- STACKIT_DISK_SIZE
- STACKIT_FLAVOUR
- STACKIT_REGION
- STACKIT_PRIVATE_KEY_PATH
- STACKIT_SERVICE_ACCOUNT_KEY_PATH
- STACKIT_AVAILABILITY_ZONE
name: "STACKIT options"
defaultVisible: true
options:
STACKIT_PROJECT_ID:
description: "Project ID to use"
required: true
password: false
default: ""
STACKIT_DISK_SIZE:
description: "The disk size to use."
required: true
password: false
default: 64GB
STACKIT_FLAVOR:
description: "The machine type to use."
default: g1.1
suggestions:
- g1.1
- g1.2
- g1.3
- g1.4
- g1a.1d
- g1a.2d
- g1a.4d
- g1a.8d
- g2i.1
- g2i.2
- g2i.4
- g2i.8
- b1.1
- b1.2
- b1a.1
- b1a.2
- b2i.1
- b2i.2
- c1.1
- c1.2
- c1.3
- c1.4
- c1.5
- c1a.16
- c1a.1
- c1a.2
- c1a.4
- c1a.8
- c2i.1
- c2i.16
- c2i.2
- c2i.4
- c2i.8
- m1.1
- m1.2
- m1.3
- m1a.1
- m1a.2
- m1a.4
- m2i.1
- m2i.2
- m2i.4
- s1.2
- s1.3
- s1.4
- s1.5
- s1a.16
- s1a.2
- s1a.4
- s1a.8
- t1.1
- t1.2
- t2i.1
STACKIT_REGION:
description: "The STACKIT region to create the VM in. e.g. eu01"
required: true
password: false
suggestions:
- eu01
default: "eu01"
STACKIT_AVAILABILITY_ZONE:
description: "The STACKIT availability zone to create the VM in. e.g. eu01"
required: true
password: false
suggestions:
- eu01-1
- eu01-2
- eu01-3
- eu01-M
default: "eu01-1"
STACKIT_PRIVATE_KEY_PATH:
description: "The location of the custom private key file"
required: false
password: false
default: ""
STACKIT_SERVICE_ACCOUNT_KEY_PATH:
description: "The location of the service account key file."
required: true
password: false
default: ""
INACTIVITY_TIMEOUT:
description: If defined, will automatically stop the VM after the inactivity period.
default: 10m
INJECT_GIT_CREDENTIALS:
description: "If DevPod should inject git credentials into the remote host."
default: "true"
INJECT_DOCKER_CREDENTIALS:
description: "If DevPod should inject docker credentials into the remote host."
default: "true"
AGENT_PATH:
description: The path where to inject the DevPod agent to.
default: /var/lib/toolbox/devpod
agent:
path: ${AGENT_PATH}
dataPath: /home/devpod/.devpod
inactivityTimeout: ${INACTIVITY_TIMEOUT}
injectGitCredentials: ${INJECT_GIT_CREDENTIALS}
injectDockerCredentials: ${INJECT_DOCKER_CREDENTIALS}
binaries:
STACKIT_PROVIDER:
{{- range file.Walk "./dist" -}}
{{- if not (file.IsDir .) -}}
{{- $parts := . | regexp.Split "_" -1 }}
{{- if eq "linux" (index $parts 1) }}
- os: {{ index $parts 1 }}
arch: {{ index $parts 2 }}
path: https://github.com/stackitcloud/devpod-provider-stackit/releases/download/{{ $.Env.VERSION }}/{{ . | filepath.Base }}
checksum: {{ . | file.Read | crypto.SHA256 }}
{{- end -}}
{{- end -}}
{{- end }}
exec:
shutdown: |-
${STACKIT_PROVIDER} stop
binaries:
STACKIT_PROVIDER:
{{- range file.Walk "./dist" -}}
{{- if not (file.IsDir .) -}}
{{- $parts := . | regexp.Split "_" -1 }}
{{- $ext := filepath.Ext . }}
- os: {{ index $parts 1 }}
arch: {{ index $parts 2 | strings.Trim $ext }}
path: https://github.com/stackitcloud/devpod-provider-stackit/releases/download/{{ $.Env.VERSION }}/{{ . | filepath.Base }}
checksum: {{ . | file.Read | crypto.SHA256 }}
{{- end -}}
{{- end }}
exec:
init: ${STACKIT_PROVIDER} init
command: ${STACKIT_PROVIDER} command
create: ${STACKIT_PROVIDER} create
delete: ${STACKIT_PROVIDER} delete
start: ${STACKIT_PROVIDER} start
stop: ${STACKIT_PROVIDER} stop
status: ${STACKIT_PROVIDER} status