Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adding ip-restriction feat #19841

Merged
merged 12 commits into from
Aug 12, 2022
Original file line number Diff line number Diff line change
Expand Up @@ -638,6 +638,16 @@
"name"
]
},
"ipSecurityRestrictionRules": {
"description": "Rules to restrict incoming IP address.",
"type": "array",
"items": {
"$ref": "#/definitions/IpSecurityRestrictionRules"
},
"x-ms-identifiers": [
"name"
]
},
"allowInsecure": {
"description": "Bool indicating if HTTP connections to is allowed. If set to false HTTP connections are automatically redirected to HTTPS connections",
"type": "boolean"
Expand Down Expand Up @@ -756,6 +766,41 @@
}
}
},
"IpSecurityRestrictionRules": {
"description": "Rules to restrict incoming IP address.",
"type": "object",
"required": [
"name",
"ipAddress",
"action"
],
"properties": {
"name": {
"description": "Name for the ip restriction rule.",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: IP (same comment in other places)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

"type": "string"
},
"description": {
"description": "Describe the IP restriction rules that are being sent to the container-app. This is an optional field.",
"type": "string"
},
"ipAddress": {
"description": "CIDR notation to match incoming ip address",
"type": "string"
},
"action": {
"description": "Allow or Deny rules to determine for incoming ip",
"enum": [
"Allow",
"Deny"
],
"type": "string",
"x-ms-enum": {
"name": "action",
"modelAsString": true
}
}
}
},
"CustomHostnameAnalysisResult": {
"description": "Custom domain analysis.",
"type": "object",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,20 @@
"revisionName": "testcontainerApp0-ab1234",
"label": "production"
}
],
"ipSecurityRestrictionRules": [
{
"name": "name",
"description": "desc",
"ipAddress": "192.168.1.1/32",
"action": "Allow"
},
{
"name": "name",
"description": "desc",
"ipAddress": "192.168.1.1/16",
"action": "Deny"
}
]
},
"dapr": {
Expand Down