นำเข้าเทมเพลต Azure Resource Manager
บท
ร่างตัวอย่าง
คุณ
เขียน
aggrega draft --example import-armจากsource ซึ่ง
cd import-armเทมเพลต
main.json คือ
{ "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#", "contentVersion": "1.0.0.0", "parameters": { "location": { "type": "string", "defaultValue": "westeurope" } }, "resources": [ { "type": "Microsoft.Network/virtualNetworks", "apiVersion": "2023-11-01", "name": "vnet-notes", "location": "[parameters('location')]", "properties": { "addressSpace": { "addressPrefixes": [ "10.20.0.0/16" ] }, "subnets": [ { "name": "snet-app", "properties": { "addressPrefix": "10.20.1.0/24", "delegations": [ { "name": "web", "properties": { "serviceName": "Microsoft.Web/serverFarms" } } ] } } ] } },[… omitted: the rest of the template]เนมสเปซavm/res/event-hub/namespace เวอร์ชัน 0.15.3: ทรัพยากร Microsoft.Resources/deployments ที่template บรรจุparameters ของ
{ "type": "Microsoft.Resources/deployments", "apiVersion": "2022-09-01", "name": "ehModule", "properties": { "mode": "Incremental", "expressionEvaluationOptions": { "scope": "inner" }, "parameters": { "name": { "value": "evh-notes" }, "location": { "value": "[parameters('location')]" }, "skuName": { "value": "Standard" }, "skuCapacity": { "value": 2 }, "publicNetworkAccess": { "value": "Enabled" }, "enableTelemetry": { "value": true } }, "template": { "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",[… omitted: the module's compiled template, and the rest of the resource]เทมเพลต
ไซต์linuxFxVersion อ่านname ของ
{ "type": "Microsoft.Web/sites", "apiVersion": "2023-12-01", "name": "notes-api", "location": "[parameters('location')]", "kind": "app,linux,container", "dependsOn": [ "[resourceId('Microsoft.Resources/deployments', 'ehModule')]", "[resourceId('Microsoft.Network/virtualNetworks', 'vnet-notes')]" ], "properties": { "serverFarmId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/notes-platform/providers/Microsoft.Web/serverfarms/plan-notes", "virtualNetworkSubnetId": "[resourceId('Microsoft.Network/virtualNetworks/subnets', 'vnet-notes', 'snet-app')]", "siteConfig": { "linuxFxVersion": "DOCKER|ghcr.io/example/notes-api:2.3.0", "appSettings": [ { "name": "EVENTHUB_NAMESPACE", "value": "[reference('ehModule').outputs.name.value]" }, { "name": "EVENTHUB_NAME", "value": "notes" } ] } } },เว็บ
{ "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#", "contentVersion": "1.0.0.0", "parameters": { "location": { "value": "northeurope" } }}ไฟล์notes และ .aggrega-config.yaml ที่
# The workspace key marks this directory as the workspace root, so an import run# here writes its drafts beside the notes folder.workspace: {}# The registry the importer is fetched from the first time an import needs it.default_registry: hub.aggrega.aiการนำ$schema และ resources และ$schema และ parameters การนำ
เปลี่ยนsource:
cd sourceรันการนำเข้า
ระบุ
aggrega import notesไม่มี--target ตัวนำarm เป็น--target จะ--sync นำ
ที่
wrote aggregate.yamlwrote release.yamlwrote manifest.yamlwrote catalog/component/imported/compute/microsoft-web-staticsites/0.1.0/component.yamlwrote catalog/recipe/arm/microsoft-web-staticsites/0.1.0/recipe.yamlwrote .aggrega-import.jsonที่<workspace> แทน
[… omitted: a warning that the importer runs unverified, printed where its module is read from beside its Plugin entity in a catalog folder rather than fetched]read as the arm format, with drafted paths relative to <workspace>info: the drafts are for the target "arm", the importer's declared default; an import naming a target drafts for that oneinfo: ehmodule deploys the Azure Verified Modules resource module avm/res/event-hub/namespace, of telemetry prefix 46d3xbcp.res.962075c, version 0.15.3, named "Event Hub Namespaces" in its metadata: it is one node of the resource type Microsoft.EventHub/namespaces, the parameters it sets read as the module's, and the module's telemetry is not carried, as whether a Recipe sends telemetry is the Recipe's to setwarn: notes-api sets the variable EVENTHUB_NAMESPACE at properties.siteConfig.appSettings.0.value from ehmodule's outputs.name.value, and the drafted Aggregate does not wire it: ehmodule publishes no provides key for it; the instance notes-api is connected to ehmodule for the dependency alone, a comment above the connection saying why; write the value where the instance is configuredinfo: the resource notes-site of the type Microsoft.Web/staticSites@2023-01-01 is drafted from the source as the Component imported/compute/microsoft-web-staticsites and the Recipe microsoft-web-staticsites on arm, carrying the properties the source writes; the decision's swap hint names the import drafting it from the vendor's schemawarn: the source creates substrate the draft leaves to the operator and drafts nothing for: vnet-notes (Microsoft.Network/virtualNetworks), of which the format says the network a component runs in is the operator's: a component of the catalog takes it by its resource ID under infra.overrides, reading the parameter location at location; provide each where the Release deploys, and fill the pointers the Release leaves for themwarn: notes-api sets the variable EVENTHUB_NAME in the environment of the instance notes-api, and the draft delivers an instance's environment from its connections alone, so the variable is not carried: the instance's Release entry names it, for the author to set where the instance is configuredmapped ehmodule (Microsoft.EventHub/namespaces) to core/messaging/azure-event-hubs as a reference, HIGH at 0.8656mapped notes-site (Microsoft.Web/staticSites) to imported/compute/microsoft-web-staticsites as a draft, NONE at 0.05made no choice for vnet-notes (Microsoft.Network/virtualNetworks)mapped notes-api (Microsoft.Web/sites) to core/compute/server as a reference, HIGH at 0.9made no choice for resourceId('Microsoft.Network/virtualNetworks/subnets', 'vnet-notes', 'snet-app') ()[… omitted: what the pull could not render yet, a stop of the App Service Recipe's assertion that the Release names the subnet, which the sections below explain] external inputs: dependency pins were written and are complete; 0 external input(s) pinned, and any this Release also needs are still unpinned external inputs: a build of this Release halts naming the unpinned URL; fixing what stopped the render and resolving again pins itPull complete: <workspace>/release.lock (entities=8, source_artifacts=0, external_inputs=0)External inputs were not fully discovered: dependency pins are complete, external-input pins may not be (see the diagnostics above)- บรรทัด
infoระบุสิ่ง ที่ ตัวนำ เข้า ตัดสิน ใจ โดย ไม่ ต้อง ถาม บรรทัด แรก บอก ว่า ฉบับ ร่าง สำหรับ armบรรทัดที่ สอง รู้จัก โมดูล: ทรัพยากร ehmoduleคือโมดูล Azure Verified Modules ของ เนมสเปซ Event Hubs และ พารามิเตอร์ ที่ เทมเพลต กำหนด ให้ เนมสเปซ นั้น อ่าน เป็น พารามิเตอร์ ของ โมดูล เอง ฉบับ ร่าง จึง ถือว่า เป็น เนมสเปซ เดียว ไม่ใช่ เทมเพลต ซ้อน ที่ ต้อง อ่าน บรรทัด ที่ สาม บอก ว่า เว็บ แอป แบบ สถิต ถูก ร่าง จาก เทมเพลต - บรรทัด
warnระบุสิ่ง ที่ ฉบับ ร่าง ไม่ บรรจุ บรรทัด แรก คือ ตัวแปร ที่ ไซต์ อ่าน จาก เอาต์พุต nameของโมดูล: ฉบับ สิ่งร่าง เชื่อม โยง การ เชื่อม ต่อ เฉพาะ สิ่ง ที่ Component เผย แพร่ และ เนมสเปซ ไม่ เผย แพร่ คีย์ สำหรับ ชื่อ ของ ตน การ เชื่อม ต่อ จึง มี ไว้ เพื่อ การ พึ่งพา เท่านั้น บรรทัด ที่ สอง ระบุ เครือข่าย เสมือน ที่ เทมเพลต สร้าง ซึ่ง ฉบับ ร่าง ฝาก ไว้ ให้ คุณ ดัง ที่ ที่ อธิบาย บรรทัดฉบับ ร่าง ฝาก ไว้ ให้ คุณ ที่ สาม ระบุ ตัวแปร ที่ ไซต์ ตั้ง ค่า ซึ่ง ไม่มี การ เชื่อม ต่อ ใด ของ ฉบับ ร่าง ส่ง มอบ - บรรทัด
mappedบอกว่า แต่ละ ทรัพยากร กลาย เป็น อะไร ehmoduleคืออินสแตนซ์ ของ core/messaging/azure-event-hubsของไลบรารี มาตรฐาน และ notes-apiคืออินสแตนซ์ ของ เซิร์ฟเวอร์ ทั่วไป core/compute/serverโดยแต่ละ รายการ จับ คู่ ใน ชั้น สูง และ ถูก อ้างอิง notes-siteไม่จับ คู่ กับ Component ใด เลย จึง เป็น ฉบับ ร่าง ที่ ไม่มี การ จับ คู่ บรรทัด made no choiceระบุสิ่ง ที่ ฉบับ ร่าง ไม่ ตัดสิน ใจ ให้: เครือข่าย เสมือน และ ตัว ชี้ ซับเน็ต ที่ Release ปล่อย ให้ ว่าง - การ pull คือ
การ ที่ การนำ เข้า ดึง สิ่ง ที่ Release ที่ ร่าง ขึ้น พึ่งพา ดัง ที่ aggrega pullทำ ลงในrelease.lockRecipes ที่ Manifest ระบุสำหรับ เนมสเปซ และ ไซต์ เขียน ทรัพยากร ของ ตนเอง และ ไม่ ดึง ซอร์ส ใด เลย source_artifactsจึงเป็น 0และ pull ไม่ต้อง ออก ไป นอก แค็ตตาล็อก เพื่อ สิ่ง ใด จาก นั้น การนำ เข้า พยายาม เรนเดอร์ Release เพื่อ หา อินพุต ที่ การ บิลด์ จะ ดึง และ Recipe App Service หยุด การ เรนเดอร์ นั้น: ฉบับ ร่าง ยัง ไม่ ระบุ ซับเน็ต การนำ เข้า ยัง จบ ลง โดย เขียน ไฟล์ ล็อก แล้ว และ บอก ว่า อินพุต ภายนอก ยัง ค้น พบ ไม่ ครบ การ หยุด นี้ คือ การ หยุด เดียว กับ ที่ การ ตรวจ สอบ ความ ถูก ต้อง รายงาน ต่อ ไป
สิ่งที่การนำเข้าเขียน
Aggregate, Release และ Manifest ใช้imported/notes ตามmain — ภายtarget_namespace ของimported เว้น
aggregate.yaml — หนึ่ง
# Sources read: main.json, main.parameters.json.# Substrate the source creates, left to the operator: vnet-notes (Microsoft.Network/virtualNetworks).apiVersion: aggrega.ai/v1beta1kind: Aggregatemetadata: name: imported/notes version: 0.1.0 description: Draft Aggregate imported from a source in the arm format.spec: components: ehmodule: type: core/messaging/azure-event-hubs notes-site: type: imported/compute/microsoft-web-staticsites values: name: "notes-site" notes-api: type: core/compute/server uses: # Not wired: notes-api sets the variable EVENTHUB_NAMESPACE at properties.siteConfig.appSettings.0.value from ehmodule's outputs.name.value; ehmodule publishes no provides key for it. ehmodule: ehmodule: target: ehmoduleเว็บimported/compute/microsoft-web-staticsites การinject เพราะ
release.yaml — สภาพ
apiVersion: aggrega.ai/v1beta1kind: Releasemetadata: name: imported/notes # environment is a drafted default, since no source names the environment this Release deploys to; change it to name the one it deploys to. environment: development version: 0.1.0 description: Draft Release imported from a source in the arm format.spec: aggregate: imported/notes manifest: imported/notes components: # Module parameters the source sets and the draft does not translate: location, name, publicNetworkAccess, skuCapacity, skuName. ehmodule: {} notes-site: infra: # From the template parameter location, the value the parameters file supplies. location: "northeurope" overrides: appLocation: "/" outputLocation: "dist" name: "Free" tier: "Free" # Properties the source writes and the draft does not place: kind, properties.siteConfig.linuxFxVersion. # Environment variables the source sets and no connection delivers: EVENTHUB_NAME = notes. notes-api: infra: overrides: service_plan_id: "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/notes-platform/providers/Microsoft.Web/serverfarms/plan-notes" # From the template parameter location, the value the parameters file supplies. location: "northeurope" # Left for the Release, since the source cannot supply it: infra.overrides.virtual_network_subnet_id, the pointer to the resource "resourceId('Microsoft.Network/virtualNetworks/subnets', 'vnet-notes', 'snet-app')", which the draft leaves to the operator and the source names as "[resourceId('Microsoft.Network/virtualNetworks/subnets', 'vnet-notes', 'snet-app')]"; the catalog Recipe takes the resource's literal identifier: write it virtual_network_subnet_id: ""สภาพdevelopment เป็นlocation ของnortheurope service_plan_id ของ
คีย์virtual_network_subnet_id คือ/subscriptions/… ตามresourceId ที่
อิมเมจlinuxFxVersion ซึ่งkind และ linuxFxVersion ไว้
manifest.yaml — Recipe ที่arm:
apiVersion: aggrega.ai/v1beta1kind: Manifestmetadata: name: imported/notes version: 0.1.0spec: mappings: components: type: {} name: ehmodule: arm/azure-event-hubs notes-site: arm/microsoft-web-staticsites notes-api: arm/server-app-serviceเว็บcatalog ของimported/compute/microsoft-web-staticsites ประกาศname ที่location และoverrides สำหรับmicrosoft-web-staticsites เขียนMicrosoft.Web/staticSites หนึ่ง
apiVersion: aggrega.ai/v1beta1kind: Componentmetadata: name: imported/compute/microsoft-web-staticsites version: 0.1.0 description: "Draft Component of the resource type Microsoft.Web/staticSites@2023-01-01, imported from a source in the arm format." labels: component.aggrega.ai/type: resource component.aggrega.ai/category: compute component.aggrega.ai/hosting: managedspec: schema: values: type: object properties: # identity: the resource's own name or identifier # The source writing the resource gives no description of name. name: type: string required: true additionalProperties: false infra: type: object properties: # placement: where the resource is deployed # The source writing the resource gives no description of location. location: type: string required: true # override: every writable property no other rule places, each under the vendor's own name overrides: type: object description: "Writable settings of Microsoft.Web/staticSites@2023-01-01, each under the vendor's own name, which the Recipe passes to the resource as written; its header lists the names it reads." additionalProperties: true additionalProperties: false[… omitted: the values the Component publishes, id and name]release.lock บันทึก.aggrega-import.json คือaggrega import --sync ใน
ตรวจสอบความถูกต้อง
aggrega validate --release release.yamlการ
[CATALOG_ERROR E0033] Recipe/FeatureRecipe assertions[… omitted: the line beginning "caused by: Recipe "server-app-service" instance "notes-api" assertion "placement_supplied"", which ends with the Recipe's message: … infra.overrides.virtual_network_subnet_id is "", and this Recipe takes the subnet the app joins by virtual network integration as the subnet's resource ID: set it to /subscriptions/<subscription>/resourceGroups/<group>/providers/Microsoft.Network/virtualNetworks/<network>/subnets/<subnet>, a subnet delegated to Microsoft.Web/serverFarms, or remove it]release dependency validation failed: 1 diagnostic(s)การnotes-api ของ release.yaml และlinuxFxVersion ซึ่งinfra.image อิมเมจ
ความskuName, skuCapacity และ location ซึ่งinfra.overrides.sku_name, infra.overrides.sku_capacity และ infra.overrides.location บรรจุreviewed ของrelease.yaml ที่
# Module parameters the source sets and the draft does not translate: location, name, publicNetworkAccess, skuCapacity, skuName. ehmodule: infra: overrides: # Where the template sets skuName and skuCapacity, which the draft places nowhere: the namespace's tier and its throughput units. sku_name: "Standard" sku_capacity: 2 # Where the template sets location, which the draft places nowhere on a module: the namespace's region. location: "northeurope"และ
# Properties the source writes and the draft does not place: kind, properties.siteConfig.linuxFxVersion. # Environment variables the source sets and no connection delivers: EVENTHUB_NAME = notes. notes-api: infra: # The template writes the container image in properties.siteConfig.linuxFxVersion, which the draft places nowhere: the image the site runs. image: "ghcr.io/example/notes-api:2.3.0" overrides: service_plan_id: "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/notes-platform/providers/Microsoft.Web/serverfarms/plan-notes" # From the template parameter location, the value the parameters file supplies. location: "northeurope" # The subnet the template's virtual network holds, as the literal ID the Recipe takes, in the resource group the network is deployed to. virtual_network_subnet_id: "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/notes-network/providers/Microsoft.Network/virtualNetworks/vnet-notes/subnets/snet-app"สคริปต์
บิลด์
ไปrelease.yaml ใน source ใน
aggrega validate --release release.yamlaggrega build --release release.yaml --auto-pullRelease ไม่release.lock ที่--auto-pull ซึ่งaggrega pull การ
release dependency validation passed: release.yaml (schema-pillar + dependency pillars)และ<workspace> แทน
[… omitted: the pull's line reporting the lockfile it wrote][… omitted: a total build time, which differs per run]Build completed: 1 file written to <workspace>/distอ่าน arm-template.json
บิลด์dist/arm/arm-template.json ซึ่งresources สำหรับ
Ehmodule the Event Hubs namespace, in a nested templateNotesApi the App Service siteNotesApiFtpPublishing the site's FTP publishing policy, which the Recipe turns offNotesApiScmPublishing the site's SCM publishing policy, which the Recipe turns offNotesSite the static web app, the resource the draft Recipe writesรายการ
"Ehmodule": { "apiVersion": "2025-04-01", "metadata": { "aggrega.ai/provenance": { "aggrega.ai/aggregate-name": "imported/notes", "aggrega.ai/boundary-path": "default",[… omitted: a compiler-version entry, which moves with the build] "aggrega.ai/component-id": "ehmodule", "aggrega.ai/environment": "development", "aggrega.ai/provider": "arm",[… omitted: a provider-version entry, which moves with the build] "aggrega.ai/recipe-uri": "azure-event-hubs:1.0.0" } }, "name": "[format('Ehmodule-{0}', uniqueString(deployment().name))]", "properties": { "expressionEvaluationOptions": { "scope": "inner" }, "mode": "Incremental", "template": { "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#", "contentVersion": "1.0.0.0", "outputs": { "serviceBusEndpoint": { "type": "string", "value": "[reference(resourceId('Microsoft.EventHub/namespaces', 'ehmodule'), '2026-01-01').serviceBusEndpoint]" } }, "resources": [ { "apiVersion": "2026-01-01", "location": "northeurope", "name": "ehmodule", "properties": { "disableLocalAuth": true, "isAutoInflateEnabled": false, "minimumTlsVersion": "1.2", "publicNetworkAccess": "Enabled" }, "sku": { "capacity": 2, "name": "Standard", "tier": "Standard" }, "type": "Microsoft.EventHub/namespaces" } ] } }, "type": "Microsoft.Resources/deployments" },รายการ
"NotesApi": { "apiVersion": "2025-03-01", "kind": "app,linux,container", "location": "northeurope", "metadata": { "aggrega.ai/provenance": { "aggrega.ai/aggregate-name": "imported/notes", "aggrega.ai/boundary-path": "default",[… omitted: a compiler-version entry, which moves with the build] "aggrega.ai/component-id": "notes-api", "aggrega.ai/environment": "development", "aggrega.ai/provider": "arm",[… omitted: a provider-version entry, which moves with the build] "aggrega.ai/recipe-uri": "server-app-service:1.0.0" } }, "name": "notes-api", "properties": { "clientAffinityEnabled": false, "httpsOnly": true, "publicNetworkAccess": "Disabled", "serverFarmId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/notes-platform/providers/Microsoft.Web/serverfarms/plan-notes", "siteConfig": { "alwaysOn": true, "appSettings": [ { "name": "WEBSITES_PORT", "value": "8080" } ], "ftpsState": "Disabled", "linuxFxVersion": "DOCKER|ghcr.io/example/notes-api:2.3.0", "minTlsVersion": "1.2", "vnetRouteAllEnabled": true }, "virtualNetworkSubnetId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/notes-network/providers/Microsoft.Network/virtualNetworks/vnet-notes/subnets/snet-app" }, "type": "Microsoft.Web/sites" },ไซต์WEBSITES_PORT และEVENTHUB_NAMESPACE และ EVENTHUB_NAME เป็นwarn และehmodule ซึ่งevh-notes โดย name ของ
ปรับใช้เทมเพลต
เทมเพลต
az deployment group what-if --resource-group <group> --template-file dist/arm/arm-template.jsonaz deployment group create --resource-group <group> --name <name> --template-file dist/arm/arm-template.jsonหน้า ARM Provider อธิบายMicrosoft.Web/serverFarms
กับผู้ช่วย AI
ผู้
ใช้เครื่องมือของ Aggrega เท่านั้น และอย่าสร้างโฟลเดอร์เอง ถ้าโฟลเดอร์พื้นที่ทำงานยังไม่มีโฟลเดอร์ `import-arm` เรียกเครื่องมือ `draft` หนึ่งครั้งโดยตั้ง `example` เป็น `import-arm` และไม่ระบุ `dir`: เครื่องมือนี้เขียนตัวอย่างลงในโฟลเดอร์ `import-arm` ใหม่ จากนั้นเรียกเครื่องมือ `import` โดยตั้ง `workspace_root` เป็น `import-arm/source` และ `source` เป็น `notes`: เครื่องมือนี้เขียนฉบับร่างลงใน `import-arm/source` และ pull สิ่งที่ฉบับร่างต้องใช้ จากนั้นเรียกเครื่องมือ `build` โดยตั้ง `workspace_root` เป็น `import-arm/reviewed`, `release` เป็น `release.yaml`, `auto_pull` เป็น true และ `write` เป็น true บอกฉันว่าบิลด์เขียนไฟล์ใดบ้าง ไฟล์เหล่านั้นอยู่ใต้ `import-arm/reviewed/dist/`โฟลเดอร์ reviewed เก็บimport-arm/source ก่อน และ
เปิดใน VS Code
เมื่อimport-arm/source ใน VS Code ซึ่งrelease.yaml ที่dist/ ของ
เมื่อเทมเพลตเปลี่ยน
เก็บ .aggrega-import.json ไว้
aggrega import notes --syncอ่านarm และoutputLocation ของdist เป็น build ใน main.json การนำ
changed spec.components.notes-site.infra.overrides.outputLocation in release.yamlและrelease.yaml โดย
เทมเพลตที่ลิงก์ไปยังเทมเพลตที่อยู่ข้างกัน
เทมเพลตMicrosoft.Resources/deployments ที่ templateLink.relativePath ระบุ
ไดเรกทอรี
halt: the sources network.json, site.json are each linked by no other source, and the root setting names none of them: set root to the path of the one to start fromการroot ระบุuri ระบุaggrega plugin add importer เขียน
plugins: importer: - uri: importer/arm:<version> with: settings: root: site.jsonเมื่อroot การนำsite.json และnetwork.json ออก
ลิงก์../shared/dns.json — จะ
warn: dns is a Microsoft.Resources/deployments resource of main.json whose template is linked by a relative path leaving the imported directory, which the import does not read: no resource of that template is drafted, and each of its outputs the template reads is carried as text evaluated when the template deploys; to draft its resources, place the linked template inside the imported directory and link it by templateLink.relativePathวาง
เมื่อชื่อถูกใช้แล้ว
ทรัพยากรimported/compute/microsoft-web-staticsites สำหรับ--output-dir second หลังcatalog ของ
warn: notes-site (Microsoft.Web/staticSites) is held back: the catalog holds the Component imported/compute/microsoft-web-staticsites a draft of it takes, which this import did not draft, so the resource is neither drafted nor referenced; to reference it, write in the importer's settings the entry {"mapping_overrides":{"arm":{"Microsoft.Web/staticSites":{"component":"imported/compute/microsoft-web-staticsites","category":"compute","traits":{"component.aggrega.ai/hosting":"managed","component.aggrega.ai/type":"resource"},"vendor":"staticsites"}}}}, then fill the instance's infra in the Releaseการmapping_overrides ของarm แล้วnotes-site ถูก
notes-site: {}Component ประกาศ name และ location เป็น
สิ่งที่ฉบับร่างทิ้งไว้ให้คุณ
การนำ
- ชั้น
รองรับ เครือข่ายที่ เทมเพลต สร้าง เพื่อ ให้ บริการ สิ่ง อื่น เสมือน vnet-notesและซับเน็ต ของ เครือข่าย มี อยู่ ใน เทมเพลต เพื่อ ไซต์ ฉบับ ร่าง ไม่ สร้าง เครือข่าย: Component ของ แค็ตตาล็อก รับ เครือข่าย ที่ ทำงาน อยู่ ผ่าน id ของ ทรัพยากร ภาย ใต้ infra.overridesและเครือข่าย เป็น ของ คุณ บรรทัด warnระบุชื่อ ทรัพยากร แต่ละ รายการ เช่น นี้ และ ตัว ชี้ ที่ อ้าง ถึง ทรัพยากร นั้น คือ คีย์ ว่าง ของ Release ใน ตำแหน่ง ที่ Release ปรับ ใช้ เครือข่าย และ ซับเน็ต มี อยู่ แล้ว หรือ คุณ ปรับ ใช้ ด้วย เทมเพลต ที่ คุณ นำ เข้า - ค่าที่
ฉบับ ความร่าง ไม่ ได้ วาง คิด เห็น ของ แต่ละ รายการ Release ระบุ พารามิเตอร์ ของ โมดูล และ คุณสมบัติ ของ ทรัพยากร ที่ ฉบับ ร่าง ไม่ ได้ วาง ซึ่ง ใน ที่ นี้ ได้แก่ ระดับ หน่วย ปริมาณ งาน ภูมิภาค และ ชื่อ ของ เนมสเปซ รวม ถึง kindและlinuxFxVersionของไซต์ เพื่อ ให้การ ตั้ง ค่า ของ เทมเพลต ถูก ระบุ ไว้ ไม่ ถูก ละทิ้ง อย่าง เงียบๆ ใน กรณี ที่ Component มี ที่ สำหรับ ค่า ใด ค่า หนึ่ง คุณ เขียน ค่า นั้น ดัง ที่ ส่วน ตรวจ สอบ ความ ถูก ต้อง ทำ - ตัวแปร
สภาพ แวดล้อม ที่ ไม่มี การ เชื่อม ต่อ ใด ส่ง มอบ EVENTHUB_NAMESPACEและEVENTHUB_NAMEของไซต์ ถูก ระบุ ชื่อ ไว้ ใน ความ คิด เห็น ของ Aggregate และ ของ Release และ ใน บรรทัด warnอย่างละ หนึ่ง บรรทัด ใน กรณี ที่ กำหนด ค่า ไซต์ ใน Release คุณ ตั้ง ค่าตัว แปร เหล่า นั้น - อิมเมจ
คอนเทนเนอร์ ฉบับร่าง บรรจุ อิมเมจ เฉพาะ เมื่อ เทมเพลต ระบุ อิมเมจ ใน คุณสมบัติ ที่ ฉบับ ร่าง วาง ไว้ เทมเพลต นี้ เขียน อิมเมจ ไว้ ใน linuxFxVersionฉบับร่าง จึง ไม่ บรรจุ อิมเมจ ใด เลย และ บิลด์ จะ หยุด โดย ระบุ infra.image: คุณต้อง จัดหา อิมเมจ ใน Release
โมดูลoci://mcr.microsoft.com/bicep/<path> โดยaggrega import --format arm-schema ซึ่ง
สตริงที่เขียนข้ามหลายบรรทัด
JSON ไม่scriptContent — จะ
[E0350] no importer recognises the source (source "main.json"). Pass --format to name it explicitly (for example --format agent-framework, --format arm-schema, --format arm, --format cloudformation-schema, --format compose, --format crewai, --format dify, --format flowise, --format google-adk, --format langflow, --format langgraph, --format mcp, --format n8n or --format terraform-schema)และ--format arm การนำ
halt: could not parse source "main.json" as arm: json parse: invalid character '\n' in string literal at line 14, column 35เขียน\n ตรง