skip to content
Alvin Lucillo

Enable container logging

/ 1 min read

To capture your app container’s stdout/stderr, use the command below. The docker-container-logging argument accepts filesystem or off.

az webapp log config \
    --resource-group $RESOURCE_GROUP \
    --name $APP_NAME \
    --docker-container-logging filesystem
{
  "httpLogs": {
    "fileSystem": {
      "enabled": true,
      "retentionInDays": 3,
      "retentionInMb": 100
    }
  },
  "name": "logs",
  "resourceGroup": "<resource-group>",
  "type": "Microsoft.Web/sites/config"
}