Skip to content

Commit e166d26

Browse files
vinisotoruslanyvinisoto
authored
Microsof.app 2022 01 01 preview/add custom domains (#17385)
* add support for Custom domains and certificates * add Certificates * Ccertificate as child resource of Managed Env. * Support default custom domain * PUT/DELETE certificate are not long-running * Add Custom Domain Verification Id * domains for all revisions and adding examples * missing examples * one more missing example * Examples+missing paths * Adding missing envelope properties * Addressing PR comments * Removing AKV and Free cert related properties * Prettier and semantic validation fixes * Fixing semantic validations and examples * More fixes * Addressing more PR comments * Updating examples * fixing type * fixing types * Extra properties and responses * misplaced response * whitespace * fix security section * fixing ManageEnvironment securityDefinitions * add 204 delete response * Removing virtual IP and IP Based option * change modelAsString * Addressing ARM PR comments * Removing 404 response from example * renaming custom hostname analysis operation * mark certificate as tracked resource * fix sample * Use Certificate Id instead of Certificate name Co-authored-by: Ruslan Yakushev 🚴 <[email protected]> Co-authored-by: vinisoto <[email protected]>
1 parent c8f6ab8 commit e166d26

12 files changed

+837
-6
lines changed

specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/ContainerApps.json

Lines changed: 185 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,58 @@
309309
}
310310
}
311311
}
312+
},
313+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/listCustomHostNameAnalysis": {
314+
"post": {
315+
"tags": [
316+
"ContainerApps"
317+
],
318+
"summary": "Analyzes a custom hostname for a Container App",
319+
"operationId": "ContainerApps_ListCustomHostNameAnalysis",
320+
"parameters": [
321+
{
322+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter"
323+
},
324+
{
325+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter"
326+
},
327+
{
328+
"name": "containerAppName",
329+
"in": "path",
330+
"description": "Name of the Container App.",
331+
"required": true,
332+
"type": "string"
333+
},
334+
{
335+
"name": "customHostname",
336+
"in": "query",
337+
"description": "Custom hostname.",
338+
"type": "string"
339+
},
340+
{
341+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter"
342+
}
343+
],
344+
"responses": {
345+
"200": {
346+
"description": "OK",
347+
"schema": {
348+
"$ref": "#/definitions/CustomHostnameAnalysisResult"
349+
}
350+
},
351+
"default": {
352+
"description": "Common error response.",
353+
"schema": {
354+
"$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse"
355+
}
356+
}
357+
},
358+
"x-ms-examples": {
359+
"Analyze Custom Hostname": {
360+
"$ref": "./examples/ContainerApps_ListCustomHostNameAnalysis.json"
361+
}
362+
}
363+
}
312364
}
313365
},
314366
"definitions": {
@@ -404,6 +456,11 @@
404456
"type": "string",
405457
"readOnly": true
406458
},
459+
"customDomainVerificationId": {
460+
"description": "Id used to verify domain name ownership",
461+
"type": "string",
462+
"readOnly": true
463+
},
407464
"configuration": {
408465
"$ref": "#/definitions/Configuration",
409466
"description": "Non versioned Container App configuration properties."
@@ -493,6 +550,16 @@
493550
"revisionName"
494551
]
495552
},
553+
"customDomains": {
554+
"description": "custom domain bindings for Container Apps' hostnames.",
555+
"type": "array",
556+
"items": {
557+
"$ref": "#/definitions/CustomDomain"
558+
},
559+
"x-ms-identifiers": [
560+
"name"
561+
]
562+
},
496563
"allowInsecure": {
497564
"description": "Bool indicating if HTTP connections to is allowed. If set to false HTTP connections are automatically redirected to HTTPS connections",
498565
"type": "boolean"
@@ -555,6 +622,124 @@
555622
"type": "boolean"
556623
}
557624
}
625+
},
626+
"CustomDomain": {
627+
"description": "Custom Domain of a Container App",
628+
"type": "object",
629+
"properties": {
630+
"name": {
631+
"description": "Hostname.",
632+
"type": "string"
633+
},
634+
"bindingType": {
635+
"description": "Custom Domain binding type.",
636+
"enum": [
637+
"Disabled",
638+
"SniEnabled"
639+
],
640+
"type": "string",
641+
"x-ms-enum": {
642+
"name": "bindingType",
643+
"modelAsString": true
644+
}
645+
},
646+
"certificateId": {
647+
"description": "Resource Id of the Certificate to be bound to this hostname. Must exist in the Managed Environment.",
648+
"type": "string"
649+
}
650+
}
651+
},
652+
"CustomHostnameAnalysisResult": {
653+
"description": "Custom domain analysis.",
654+
"type": "object",
655+
"allOf": [
656+
{
657+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ProxyResource"
658+
}
659+
],
660+
"properties": {
661+
"properties": {
662+
"description": "CustomHostnameAnalysisResult resource specific properties",
663+
"type": "object",
664+
"properties": {
665+
"hostName": {
666+
"description": "Host name that was analyzed",
667+
"type": "string",
668+
"readOnly": true
669+
},
670+
"isHostnameAlreadyVerified": {
671+
"description": "<code>true</code> if hostname is already verified; otherwise, <code>false</code>.",
672+
"type": "boolean",
673+
"readOnly": true
674+
},
675+
"customDomainVerificationTest": {
676+
"description": "DNS verification test result.",
677+
"enum": [
678+
"Passed",
679+
"Failed",
680+
"Skipped"
681+
],
682+
"type": "string",
683+
"readOnly": true,
684+
"x-ms-enum": {
685+
"name": "DnsVerificationTestResult",
686+
"modelAsString": false
687+
}
688+
},
689+
"customDomainVerificationFailureInfo": {
690+
"$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse",
691+
"description": "Raw failure information if DNS verification fails.",
692+
"readOnly": true
693+
},
694+
"hasConflictOnManagedEnvironment": {
695+
"description": "<code>true</code> if there is a conflict on the Container App's managed environment; otherwise, <code>false</code>.",
696+
"type": "boolean",
697+
"readOnly": true
698+
},
699+
"conflictingContainerAppResourceId": {
700+
"description": "Name of the conflicting Container App on the Managed Environment if it's within the same subscription.",
701+
"type": "string",
702+
"readOnly": true
703+
},
704+
"cNameRecords": {
705+
"description": "CName records visible for this hostname.",
706+
"type": "array",
707+
"items": {
708+
"type": "string"
709+
}
710+
},
711+
"txtRecords": {
712+
"description": "TXT records visible for this hostname.",
713+
"type": "array",
714+
"items": {
715+
"type": "string"
716+
}
717+
},
718+
"aRecords": {
719+
"description": "A records visible for this hostname.",
720+
"type": "array",
721+
"items": {
722+
"type": "string"
723+
}
724+
},
725+
"alternateCNameRecords": {
726+
"description": "Alternate CName records visible for this hostname.",
727+
"type": "array",
728+
"items": {
729+
"type": "string"
730+
}
731+
},
732+
"alternateTxtRecords": {
733+
"description": "Alternate TXT records visible for this hostname.",
734+
"type": "array",
735+
"items": {
736+
"type": "string"
737+
}
738+
}
739+
},
740+
"x-ms-client-flatten": true
741+
}
742+
}
558743
}
559744
},
560745
"securityDefinitions": {

0 commit comments

Comments
 (0)