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/sentinel/ci-cd-custom-deploy.md
+20-11Lines changed: 20 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -156,6 +156,23 @@ For more information, see the [Azure DevOps documentation](/azure/devops/pipelin
156
156
> In both GitHub and Azure DevOps, make sure that you keep the trigger path and deployment path directories consistent.
157
157
>
158
158
159
+
## Scale your deployments with parameter files
160
+
161
+
Rather than passing parameters as inline values in your content files, you can [use a JSON file that contains the parameter values](../azure-resource-manager/templates/parameter-files.md). You can then map those parameter JSON files to their associated Sentinel content files to better scale your deployments across different workspaces. There are a number of ways to map parameter files to Sentinel files, and the repositories deployment pipeline considers them in the following order:
162
+
163
+
:::image type="content" source="media/ci-cd-custom-deploy/deploy-parameter-file-precedence.svg" alt-text="A diagram showing the precedence of parameter file mappings.":::
164
+
165
+
1. Is there a mapping in the sentinel-deployment.config? [Customize your connection configuration](ci-cd-custom-deploy.md#customize-your-connection-configuration) to learn more.
166
+
1. Is there a workspace-mapped parameter file? This would be a parameter file in the same directory as the content files that ends with .parameters-<WorkspaceID>.json
167
+
1. Is there a default parameter file? This would be any parameter file in the same directory as the content files that ends with .parameters.json
168
+
169
+
It is encouraged to map your parameter files through through the configuration file or by specifying the workspace ID in the file name to avoid clashes in scenarios with multiple deployments.
170
+
171
+
> [!IMPORTANT]
172
+
> Once a parameter file match is determined based on the above mapping precedence, the pipeline will ignore any remaining mappings.
173
+
>
174
+
175
+
Modifying the mapped parameter file listed in the sentinel-deployment.config will trigger the deployment of its paired content file. Adding or modifying a *.parameters-\<workspaceID\>.json* file or *.parameters.json* file will also trigger a deployment of the paired content file(s) along with the newly modified parameters, unless a higher precedence parameter mappings is in place. Other content files won't be deployed as long as the smart deployments feature is still enabled in the workflow/pipeline definition file.
159
176
160
177
## Customize your connection configuration
161
178
@@ -203,19 +220,11 @@ Here's an example of the entire contents of a valid *sentinel-deployment.config*
203
220
204
221
Add full path names to the `"prioritizedcontentfiles":` section. Wildcard matching is not supported at this time.
205
222
206
-
- **To exclude content files**, modify the `"excludecontentfiles":` section with full path names of individual .json deployment files.
223
+
- **To exclude content files**, modify the `"excludecontentfiles":` section with full path names of individual .json content files.
207
224
208
225
- **To map parameters**:
209
226
210
-
The deployment script will accept three methods to map parameters. The precedence is determined for each included .json deployment file in your repository as follows:
211
-
212
-
:::image type="content" source="media/ci-cd-custom-deploy/deploy-parameter-file-precedence.svg" alt-text="A diagram showing the precedence of parameter file mappings.":::
213
-
214
-
1. Is there a mapping in the sentinel-deployment.config?
215
-
1. Is there a workspace parameter file?
216
-
1. Is there a default parameter file?
217
-
218
-
Modifying the mapped parameter file listed in the sentinel-deployment.config will trigger the deployment of its paired content file. Adding or modifying a *.parameters-\<workspaceID\>.json* file or *.parameters.json* file triggers a deployment of that corresponding content file along with the newly modified parameters, unless a higher precedence parameter mappings is in place. Other content files won't be deployed if the smart deployments feature is still enabled.
227
+
The deployment script will accept three methods of mapping parameters as described in [Scale your deployments with parameter files](ci-cd-custom-deploy.md#scale-your-deployments-with-parameter-files). Mapping parameters through the sentinel-deployment.config takes the highest precedence and will guarantee that a given parameter file will be mapped to its associated content files. Simply modify the `"parameterfilemappings":` section with your target connection's workspace ID and full path names of individual .json files.
0 commit comments