|
1 | | -### YamlMime:ModuleUnit |
2 | | -uid: learn.azure.deploy-azure-resources-bicep.knowledge-check |
3 | | -title: Module assessment |
4 | | -metadata: |
5 | | - unitType: knowledge_check |
6 | | - title: Module assessment |
7 | | - description: "Knowledge check" |
8 | | - ms.date: 01/31/2025 |
9 | | - author: mumian |
10 | | - ms.author: jgao |
11 | | - ms.topic: unit |
12 | | - ms.custom: |
13 | | - - devx-track-bicep |
14 | | - module_assessment: true |
15 | | -durationInMinutes: 3 |
16 | | -content: | |
17 | | - [!include[](includes/9-knowledge-check.md)] |
18 | | -quiz: |
19 | | - questions: |
20 | | - - content: What's the best way for the team to create a template that deploys to both test and production environments? |
21 | | - choices: |
22 | | - - content: Create a template that deploys all of the resources for the manufacturing application. Add template parameters for the values that might change between environments. |
23 | | - isCorrect: true |
24 | | - explanation: Correct. Template parameters are a great way to manage multiple environments. You can specify different values for the parameters when you deploy the template into the test and production environments. |
25 | | - - content: Create a module that deploys all of the resources for the manufacturing application. Create separate Bicep templates for each environment, and add the shared module to each environment's template. |
26 | | - isCorrect: false |
27 | | - explanation: Incorrect. Modules can be a great way to reuse your Bicep code, but when you're deploying multiple environments, there's usually a simpler way to keep track of the different configurations for each deployment. |
28 | | - - content: Create a template that deploys all of the resources required for the manufacturing application. Add variables for the values that might change between environments. |
29 | | - isCorrect: false |
30 | | - explanation: Incorrect. Variables have the same value, so you don't usually need to consider them when you deploy multiple environments. |
31 | | - - content: | |
32 | | - The template that the team has developed includes this line:<br /> |
33 | | - `param siteName string = 'mysite-${uniqueString(resourceGroup().id)}'`<br /> |
34 | | - Which of these statements is true? |
35 | | - choices: |
36 | | - - content: Whoever deploys the template must specify a value for the `siteName` parameter. |
37 | | - isCorrect: false |
38 | | - explanation: Incorrect. The `siteName` parameter has a _default value_ specified, which means that deployments don't have to specify the parameter value. If they don't, the parameter's default value is used. |
39 | | - - content: The `siteName` parameter will have a different default value every time the template is deployed. |
40 | | - isCorrect: false |
41 | | - explanation: Incorrect. The parameter's default value is set through the `uniqueString()` function, which has been seeded with the resource group's ID. Therefore, the value that the `uniqueString()` function returns is the same whenever the template is deployed in the same resource group in the same Azure subscription. |
42 | | - - content: When the template is deployed to the same resource group in the same subscription repeatedly, the `siteName` parameter's default value will be the same each time. |
43 | | - isCorrect: true |
44 | | - explanation: Correct. The `siteName` parameter's default value uses string interpolation to combine the string prefix `mysite-` with a value from the `uniqueString()` function, which is seeded with the resource group ID. The value that the `uniqueString()` function returns is the same whenever the template is deployed in the same resource group in the same Azure subscription. |
45 | | - - content: The Bicep template that the IT department wrote has two modules in it. Which of these statements is true? |
46 | | - choices: |
47 | | - - content: If an output is added to one of the modules, it's automatically published as an output from the parent template too. |
48 | | - isCorrect: false |
49 | | - explanation: Incorrect. Outputs that Bicep modules define are available to the parent template, but they aren't automatically available to the template deployer. However, you can define an output in your template and pass the value through. |
50 | | - - content: If an output is added to one of the modules, it will automatically be available for the parent template to use. |
51 | | - isCorrect: true |
52 | | - explanation: Correct. The outputs from modules are automatically made available for the parent template to use, such as in defining input parameter values for other modules or in setting the properties on resources. |
53 | | - - content: Modules can't have outputs; only templates can. |
54 | | - isCorrect: false |
55 | | - explanation: Incorrect. Modules can define outputs. The outputs from modules are automatically made available to the parent template. |
56 | | - |
| 1 | +### YamlMime:ModuleUnit |
| 2 | +uid: learn.azure.deploy-azure-resources-bicep.knowledge-check |
| 3 | +title: Module assessment |
| 4 | +metadata: |
| 5 | + unitType: knowledge_check |
| 6 | + title: Module assessment |
| 7 | + description: "Knowledge check" |
| 8 | + ms.date: 01/31/2025 |
| 9 | + author: mumian |
| 10 | + ms.author: jgao |
| 11 | + ms.topic: unit |
| 12 | + ms.custom: |
| 13 | + - devx-track-bicep |
| 14 | + module_assessment: true |
| 15 | +durationInMinutes: 3 |
| 16 | +content: | |
| 17 | + [!include[](includes/9-knowledge-check.md)] |
| 18 | +quiz: |
| 19 | + questions: |
| 20 | + - content: What's the best way for the team to create a template that deploys to both test and production environments? |
| 21 | + choices: |
| 22 | + - content: Create a template that deploys all of the resources for the manufacturing application. Add template parameters for the values that might change between environments. |
| 23 | + isCorrect: true |
| 24 | + explanation: Correct. Template parameters are a great way to manage multiple environments. You can specify different values for the parameters when you deploy the template into the test and production environments. |
| 25 | + - content: Create a module that deploys all of the resources for the manufacturing application. Create separate Bicep templates for each environment, and add the shared module to each environment's template. |
| 26 | + isCorrect: false |
| 27 | + explanation: Incorrect. Modules can be a great way to reuse your Bicep code, but when you're deploying multiple environments, there's usually a simpler way to keep track of the different configurations for each deployment. |
| 28 | + - content: Create a template that deploys all of the resources required for the manufacturing application. Add variables for the values that might change between environments. |
| 29 | + isCorrect: false |
| 30 | + explanation: Incorrect. Variables have the same value, so you don't usually need to consider them when you deploy multiple environments. |
| 31 | + - content: | |
| 32 | + The template that the team has developed includes this line:<br /> |
| 33 | + `param siteName string = 'mysite-${uniqueString(resourceGroup().id)}'`<br /> |
| 34 | + Which of these statements is true? |
| 35 | + choices: |
| 36 | + - content: Whoever deploys the template must specify a value for the `siteName` parameter. |
| 37 | + isCorrect: false |
| 38 | + explanation: Incorrect. The `siteName` parameter has a _default value_ specified, which means that deployments don't have to specify the parameter value. If they don't, the parameter's default value is used. |
| 39 | + - content: The `siteName` parameter will have a different default value every time the template is deployed. |
| 40 | + isCorrect: false |
| 41 | + explanation: Incorrect. The parameter's default value is set through the `uniqueString()` function, which has been seeded with the resource group's ID. Therefore, the value that the `uniqueString()` function returns is the same whenever the template is deployed in the same resource group in the same Azure subscription. |
| 42 | + - content: When the template is deployed to the same resource group in the same subscription repeatedly, the `siteName` parameter's default value will be the same each time. |
| 43 | + isCorrect: true |
| 44 | + explanation: Correct. The `siteName` parameter's default value uses string interpolation to combine the string prefix `mysite-` with a value from the `uniqueString()` function, which is seeded with the resource group ID. The value that the `uniqueString()` function returns is the same whenever the template is deployed in the same resource group in the same Azure subscription. |
| 45 | + - content: The Bicep template that the IT department wrote has two modules in it. Which of these statements is true? |
| 46 | + choices: |
| 47 | + - content: If an output is added to one of the modules, it's automatically published as an output from the parent template too. |
| 48 | + isCorrect: false |
| 49 | + explanation: Incorrect. Outputs that Bicep modules define are available to the parent template, but they aren't automatically available to the template deployer. However, you can define an output in your template and pass the value through. |
| 50 | + - content: If an output is added to one of the modules, it will automatically be available for the parent template to use. |
| 51 | + isCorrect: true |
| 52 | + explanation: Correct. The outputs from modules are automatically made available for the parent template to use, such as in defining input parameter values for other modules or in setting the properties on resources. |
| 53 | + - content: Modules can't have outputs; only templates can. |
| 54 | + isCorrect: false |
| 55 | + explanation: Incorrect. Modules can define outputs. The outputs from modules are automatically made available to the parent template. |
| 56 | + |
0 commit comments