curl --request PUT \
--url https://api.bunny.net/mc/apps/{appId}/containers/{containerId}/env \
--header 'AccessKey: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'{
"id": "<string>",
"name": "<string>",
"packageId": "<string>",
"image": "<string>",
"imageName": "<string>",
"imageNamespace": "<string>",
"imageTag": "<string>",
"imageRegistryId": "<string>",
"imageDigest": "<string>",
"imagePullPolicy": "Always",
"entryPoint": {
"command": "<string>",
"commandArray": [
"<string>"
],
"arguments": "<string>",
"argumentsArray": [
"<string>"
],
"workingDirectory": "<string>"
},
"probes": {
"startup": {
"initialDelaySeconds": 10,
"periodSeconds": 10,
"timeoutSeconds": 7,
"failureThreshold": 3,
"successThreshold": 1,
"httpGet": {
"request": {
"path": "<string>",
"portNumber": 32768
},
"response": {
"expectedStatusCode": "Continue"
}
},
"tcpSocket": {
"request": {
"portNumber": 32768
}
},
"grpc": {
"request": {
"portNumber": 32768,
"serviceName": "<string>"
}
}
},
"readiness": {
"initialDelaySeconds": 10,
"periodSeconds": 10,
"timeoutSeconds": 7,
"failureThreshold": 3,
"successThreshold": 1,
"httpGet": {
"request": {
"path": "<string>",
"portNumber": 32768
},
"response": {
"expectedStatusCode": "Continue"
}
},
"tcpSocket": {
"request": {
"portNumber": 32768
}
},
"grpc": {
"request": {
"portNumber": 32768,
"serviceName": "<string>"
}
}
},
"liveness": {
"initialDelaySeconds": 10,
"periodSeconds": 10,
"timeoutSeconds": 7,
"failureThreshold": 3,
"successThreshold": 1,
"httpGet": {
"request": {
"path": "<string>",
"portNumber": 32768
},
"response": {
"expectedStatusCode": "Continue"
}
},
"tcpSocket": {
"request": {
"portNumber": 32768
}
},
"grpc": {
"request": {
"portNumber": 32768,
"serviceName": "<string>"
}
}
}
},
"environmentVariables": [
{
"name": "<string>",
"value": "<string>"
}
],
"endpoints": [
{
"displayName": "<string>",
"publicHost": "<string>",
"type": "CDN",
"isSslEnabled": true,
"pullZoneId": "<string>",
"portMappings": [
{
"containerPort": 123,
"exposedPort": 123,
"protocols": [
"Tcp"
]
}
],
"stickySessions": {
"enabled": true,
"sessionHeaders": [
"<string>"
],
"cookieName": "<string>"
},
"internalIpAddresses": [
{
"address": "<string>",
"region": "<string>"
}
],
"publicIpAddresses": [
{
"address": "<string>",
"region": "<string>"
}
]
}
],
"volumeMounts": [
{
"name": "<string>",
"mountPath": "<string>"
}
]
}Replaces all environment variables for a container template. All existing environment variables will be removed and replaced with the provided set.
curl --request PUT \
--url https://api.bunny.net/mc/apps/{appId}/containers/{containerId}/env \
--header 'AccessKey: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'{
"id": "<string>",
"name": "<string>",
"packageId": "<string>",
"image": "<string>",
"imageName": "<string>",
"imageNamespace": "<string>",
"imageTag": "<string>",
"imageRegistryId": "<string>",
"imageDigest": "<string>",
"imagePullPolicy": "Always",
"entryPoint": {
"command": "<string>",
"commandArray": [
"<string>"
],
"arguments": "<string>",
"argumentsArray": [
"<string>"
],
"workingDirectory": "<string>"
},
"probes": {
"startup": {
"initialDelaySeconds": 10,
"periodSeconds": 10,
"timeoutSeconds": 7,
"failureThreshold": 3,
"successThreshold": 1,
"httpGet": {
"request": {
"path": "<string>",
"portNumber": 32768
},
"response": {
"expectedStatusCode": "Continue"
}
},
"tcpSocket": {
"request": {
"portNumber": 32768
}
},
"grpc": {
"request": {
"portNumber": 32768,
"serviceName": "<string>"
}
}
},
"readiness": {
"initialDelaySeconds": 10,
"periodSeconds": 10,
"timeoutSeconds": 7,
"failureThreshold": 3,
"successThreshold": 1,
"httpGet": {
"request": {
"path": "<string>",
"portNumber": 32768
},
"response": {
"expectedStatusCode": "Continue"
}
},
"tcpSocket": {
"request": {
"portNumber": 32768
}
},
"grpc": {
"request": {
"portNumber": 32768,
"serviceName": "<string>"
}
}
},
"liveness": {
"initialDelaySeconds": 10,
"periodSeconds": 10,
"timeoutSeconds": 7,
"failureThreshold": 3,
"successThreshold": 1,
"httpGet": {
"request": {
"path": "<string>",
"portNumber": 32768
},
"response": {
"expectedStatusCode": "Continue"
}
},
"tcpSocket": {
"request": {
"portNumber": 32768
}
},
"grpc": {
"request": {
"portNumber": 32768,
"serviceName": "<string>"
}
}
}
},
"environmentVariables": [
{
"name": "<string>",
"value": "<string>"
}
],
"endpoints": [
{
"displayName": "<string>",
"publicHost": "<string>",
"type": "CDN",
"isSslEnabled": true,
"pullZoneId": "<string>",
"portMappings": [
{
"containerPort": 123,
"exposedPort": 123,
"protocols": [
"Tcp"
]
}
],
"stickySessions": {
"enabled": true,
"sessionHeaders": [
"<string>"
],
"cookieName": "<string>"
},
"internalIpAddresses": [
{
"address": "<string>",
"region": "<string>"
}
],
"publicIpAddresses": [
{
"address": "<string>",
"region": "<string>"
}
]
}
],
"volumeMounts": [
{
"name": "<string>",
"mountPath": "<string>"
}
]
}Please enter a valid personal API key.
The ID of the application
The ID of the container template
A JSON object where each key is the variable name and each value is the variable value
Environment variables were successfully replaced.
Container template model
111111111Always, IfNotPresent Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?