Skip to content

Commit fa16f05

Browse files
authored
feat(baremetal): expose user_data field for cloud-init (scaleway#2788)
1 parent f58066b commit fa16f05

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

api/baremetal/v1/baremetal_sdk.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1212,6 +1212,9 @@ type CreateServerRequest struct {
12121212

12131213
// Protected: if enabled, the server can not be deleted.
12141214
Protected bool `json:"protected"`
1215+
1216+
// UserData: configuration data to pass to cloud-init such as a YAML cloud config data or a user-data script.
1217+
UserData *[]byte `json:"user_data,omitempty"`
12151218
}
12161219

12171220
// Server: server.
@@ -1278,6 +1281,9 @@ type Server struct {
12781281

12791282
// Protected: if enabled, the server can not be deleted.
12801283
Protected bool `json:"protected"`
1284+
1285+
// UserData: optional configuration data passed to cloud-init.
1286+
UserData *[]byte `json:"user_data"`
12811287
}
12821288

12831289
// OS: os.
@@ -1653,6 +1659,9 @@ type InstallServerRequest struct {
16531659

16541660
// PartitioningSchema: partitioning schema.
16551661
PartitioningSchema *Schema `json:"partitioning_schema,omitempty"`
1662+
1663+
// Deprecated: UserData: configuration data to pass to cloud-init such as a YAML cloud config data or a user-data script.
1664+
UserData *scw.File `json:"user_data,omitempty"`
16561665
}
16571666

16581667
// ListOSRequest: list os request.
@@ -2147,6 +2156,9 @@ type UpdateServerRequest struct {
21472156

21482157
// Protected: if enabled, the server can not be deleted.
21492158
Protected *bool `json:"protected,omitempty"`
2159+
2160+
// UserData: configuration data to pass to cloud-init such as a YAML cloud config data or a user-data script.
2161+
UserData *[]byte `json:"user_data,omitempty"`
21502162
}
21512163

21522164
// UpdateSettingRequest: update setting request.

0 commit comments

Comments
 (0)