. _contexamples:
Container example declarations¶
1: Using Declarative Onboarding in a container¶
The following is an example of a declaration for use in a container. It contains the DO class, which contains information about the target BIG-IP device. See Using Declarative Onboarding in a Docker Container for information about the container and the DO class.
The items specific to the DO class are highlighted.
{
"class": "DO",
"targetHost": "1.2.3.4",
"targetUsername": "admin",
"targetPassphrase": "myAdminPassword",
"declaration": {
"schemaVersion": "1.0.0",
"class": "Device",
"label": "Use App Services Gateway to onboard a BIG-IP",
"Common": {
"class": "Tenant",
"hostname": "bigip.example.com",
"dbvars": {
"class": "DbVariables",
"ui.advisory.enabled": true,
"ui.advisory.color": "green",
"ui.advisory.text": "/Common/hostname"
},
"myLicense": {
"class": "License",
"licenseType": "regKey",
"regKey": "MMKGX-UPVPI-YIEMK-OAZIS-KQHSNAZ"
},
"myDns": {
"class": "DNS",
"nameServers": [
"8.8.8.8",
"2001:4860:4860::8844"
],
"search": [
"f5.com"
]
},
"myNtp": {
"class": "NTP",
"servers": [
"0.pool.ntp.org",
"1.pool.ntp.org",
"2.pool.ntp.org"
],
"timezone": "UTC"
},
"root": {
"class": "User",
"userType": "root",
"oldPassword": "foo",
"newPassword": "bar"
},
"admin": {
"class": "User",
"userType": "regular",
"password": "asdfjkl",
"shell": "bash"
},
"guestUser": {
"class": "User",
"userType": "regular",
"password": "foobar",
"partitionAccess": {
"Common": {
"role": "guest"
}
}
},
"anotherUser": {
"class": "User",
"userType": "regular",
"password": "foobar",
"shell": "none",
"partitionAccess": {
"all-partitions": {
"role": "guest"
}
}
},
"myProvisioning": {
"class": "Provision",
"ltm": "nominal"
},
"internal": {
"class": "VLAN",
"tag": 4093,
"mtu": 1500,
"interfaces": [
{
"name": "1.2",
"tagged": true
}
]
},
"internal-self": {
"class": "SelfIp",
"address": "10.10.0.100/24",
"vlan": "internal",
"allowService": "default",
"trafficGroup": "traffic-group-local-only"
},
"external": {
"class": "VLAN",
"tag": 4094,
"mtu": 1500,
"interfaces": [
{
"name": "1.1",
"tagged": true
}
]
},
"external-self": {
"class": "SelfIp",
"address": "10.20.0.100/24",
"vlan": "external",
"allowService": "none",
"trafficGroup": "traffic-group-local-only"
},
"default": {
"class": "Route",
"gw": "10.10.0.1",
"network": "default",
"mtu": 1500
}
}
}
}