You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/azure-resource-manager/bicep/parameter-files.md
+34-5Lines changed: 34 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,9 @@
1
1
---
2
2
title: Create parameters files for Bicep deployment
3
-
description: Create parameters file for passing in values during deployment of a Bicep file
3
+
description: Create parameters file for passing in values during deployment of a Bicep file.
4
4
ms.topic: conceptual
5
5
ms.custom: devx-track-bicep
6
-
ms.date: 01/17/2024
6
+
ms.date: 03/19/2024
7
7
---
8
8
9
9
# Create parameters files for Bicep deployment
@@ -15,7 +15,7 @@ Rather than passing parameters as inline values in your script, you can use a Bi
15
15
16
16
A single Bicep file can have multiple Bicep parameters files associated with it. However, each Bicep parameters file is intended for one particular Bicep file. This relationship is established using the [`using` statement](./bicep-using.md) within the Bicep parameters file.
17
17
18
-
You can compile Bicep parameters files into JSON parameters files to deploy with a Bicep file. See [build-params](./bicep-cli.md#build-params). You can also decompile a JSON parameters file into a Bicep parameters file. See [decompile-params](./bicep-cli.md#decompile-params).
18
+
You can compile Bicep parameters files into JSON parameters files to deploy with a Bicep file. See [build-params](./bicep-cli.md#build-params). You can also decompile a JSON parameters file into a Bicep parameters file. See [decompile-params](./bicep-cli.md#decompile-params).
You can use the [using statement](./bicep-using.md) with Bicep file, ARM JSON templates, Bicep modules, and template specs. For example:
34
+
35
+
```bicep
36
+
using './main.bicep'
37
+
...
38
+
```
39
+
40
+
```bicep
41
+
using './azuredeploy.json'
42
+
...
43
+
```
44
+
45
+
```bicep
46
+
using 'br/public:storage/storage-account:3.0.1'
47
+
...
48
+
```
49
+
50
+
```bicep
51
+
using 'br:myacr.azurecr.io/bicep/modules/storage:v1'
52
+
...
53
+
```
54
+
55
+
```bicep
56
+
using 'ts:00000000-0000-0000-0000-000000000000/myResourceGroup/storageSpec:1.0'
57
+
...
58
+
```
59
+
60
+
For more information, see the [using statement](./bicep-using.md).
61
+
33
62
You can use expressions with the default value. For example:
34
63
35
64
```bicep
@@ -328,15 +357,15 @@ To generate a parameters file, you have two options: either through Visual Studi
328
357
329
358
## Build Bicep parameters file
330
359
331
-
From Bicep CLI, you can build a Bicep parameters file into a JSON parameters file. for more information, see [Build parameters file](./bicep-cli.md#build-params).
360
+
From Bicep CLI, you can build a Bicep parameters file into a JSON parameters file. For more information, see [Build parameters file](./bicep-cli.md#build-params).
332
361
333
362
## Deploy Bicep file with parameters file
334
363
335
364
From Azure CLI, you can pass a parameter file with your Bicep file deployment.
336
365
337
366
# [Bicep parameters file](#tab/Bicep)
338
367
339
-
With Azure CLI version 2.53.0 or later, and [Bicep CLI version 0.22.X or higher](./install.md), you can deploy a Bicep file by utilizing a Bicep parameter file. With the `using` statement within the Bicep parameters file, there is no need to provide the `--template-file` switch when specifying a Bicep parameter file for the `--parameters` switch. Including the `--template-file` switch will result in an "Only a .bicep template is allowed with a .bicepparam file" error.
368
+
With Azure CLI version 2.53.0 or later, and [Bicep CLI version 0.22.X or higher](./install.md), you can deploy a Bicep file by utilizing a Bicep parameter file. With the `using` statement within the Bicep parameters file, there's no need to provide the `--template-file` switch when specifying a Bicep parameter file for the `--parameters` switch. Including the `--template-file` switch results in an "Only a .bicep template is allowed with a .bicepparam file" error.
0 commit comments