This repository has been archived by the owner on Jul 16, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ops.props
471 lines (395 loc) · 20.1 KB
/
ops.props
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
<?xml version="1.0" encoding="utf-8"?>
<Project
DefaultTargets="Run"
ToolsVersion="14.0"
xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- Overrides for the project specific properties -->
<PropertyGroup>
<!--
The name of the product. This is for instance used for:
* Copyrights
* API documentation
-->
<ProductName>Base.Vm.Linux</ProductName>
<!--
The name of the product that can be used as part of a file path. This is for instance used for:
* Deployment directory naming
-->
<ProductNameInFilePath>Base.Vm.Linux</ProductNameInFilePath>
<!--
The namespace in which all the code for the product is placed. This is for instance used for:
* Finding the correct assemblies and namespaces for unit testing and coverage reporting
* Generated code files that contain namespaces
-->
<ProductNamespace>Base.Vm.Linux</ProductNamespace>
<!--
The URL of the product website. This is for instance used for:
* nuspec files
-->
<ProductUrl>https://github.com/Calvinverse/base.vm.linux</ProductUrl>
<!--
The first year the product was available / created. This is for instance used for:
* Copyrights
-->
<ProductStartingYear>2017</ProductStartingYear>
<!--
The name of the company. This is for instance used for:
* Copyrights
* API documentation
-->
<CompanyName>Calvinverse</CompanyName>
<!--
The name of the company that can be used as a part of a file path. This is for instance used for:
* Installer file paths
-->
<CompanyNameInFilePath>calvinverse</CompanyNameInFilePath>
<!--
The URL of the company website. This is for instance used for:
* nuspec files
-->
<CompanyUrl>https://github.com/Calvinverse</CompanyUrl>
</PropertyGroup>
<!--
Overrides for the VCS specific properties
-->
<PropertyGroup>
<!-- The user name of the user who owns the repository on GitHub -->
<GitHubUserName>calvinverse</GitHubUserName>
<!--
The github repository that contains the source code for the current product. Used when getting the release notes
from the github issues, e.g. nbuildkit.
-->
<GitHubRepositoryName>base.vm.linux</GitHubRepositoryName>
<!--
The full URL to the GIT repository. Can include the '%GitHubToken%' environment variable for authenticated
connection to the repository, e.g. https://%GitHubToken%:@github.com/MyUser/MyProject.git
-->
<GitRemoteRepository>https://%GitHubToken%:@github.com/$(GitHubUserName)/$(GitHubRepositoryName).git</GitRemoteRepository>
</PropertyGroup>
<!--
Defines the custom version numbers that should be available for template replacement.
The template consists of a name and a version number string. The name will be used as the
name of the template, i.e. 'VersionAssembly' will be available in the collection of template
parameters available for replacement.
Each version number may consist of zero or more template parameters. Template parameters
must be enclosed in '${}', e.g. ${VersionMajor} will be replaced by the major version number
as indicated at the top of the file.
Note that custom version number templates may not reference other custom version number templates.
-->
<ItemGroup>
<!--
The template for the version number that will be used in the 'AssemblyVersionAttribute' in the
'AssemblyInfo.VersionNumber.xx' file which can be generated if the 'ShouldGenerateAssemblyVersionInfo'
property is set to 'true'
-->
<!--
<TemplateVersion Include="VersionAssembly">
<Template>${VersionMajor}.${VersionMinor}.0.0</Template>
</TemplateVersion>
-->
<!--
The template for the version number that will be used in the 'AssemblyFileVersionAttribute' in the
'AssemblyInfo.VersionNumber.xx' file which can be generated if the 'ShouldGenerateAssemblyVersionInfo'
property is set to 'true'
-->
<!--
<TemplateVersion Include="VersionAssemblyFile">
<Template>${VersionMajor}.${VersionMinor}.${VersionPatch}.${VersionBuild}</Template>
</TemplateVersion>
-->
<!--
The template for the version number that will be used in the 'AssemblyInformationalVersionAttribute' in the
'AssemblyInfo.VersionNumber.xx' file which can be generated if the 'ShouldGenerateAssemblyVersionInfo'
property is set to 'true'
Also used as the 'ApplicationVersion' in the 'VersionNumber.wxi' file.
-->
<!--
<TemplateVersion Include="VersionProduct">
<Template>${VersionSemanticFull}</Template>
</TemplateVersion>
-->
<!--
The template for the version number that will be used as the 'InstallVersion' in the
'VersionNumber.wxi' file which can be generated if the 'ShouldGenerateAssemblyVersionInfo'
property is set to 'true'
-->
<!--
<TemplateVersion Include="VersionInstall">
<Template>${VersionMajor}.${VersionMinor}.${VersionPatch}</Template>
</TemplateVersion>
-->
<!--
The template for the version number that will be used as the 'ProductVersionFolder' in the
'VersionNumber.wxi' file which can be generated if the 'ShouldGenerateAssemblyVersionInfo'
property is set to 'true'
-->
<!--
<TemplateVersion Include="VersionInstallFilePath">
<Template>${VersionMajor}.${VersionMinor}</Template>
</TemplateVersion>
-->
</ItemGroup>
<!--
Directories
-->
<PropertyGroup>
<!--
NOTE: The 'DirWorkspace' property is always set prior to loading the current file. The variable is set
to the directory which contains the current file.
-->
<!-- The directory that will contain all the files generated during the build process -->
<!-- <DirBuild>$(DirWorkspace)\build</DirBuild> -->
<!--
The directory that will contain all the binaries generated during the build process.
Note that there may be configuration and platform specific sub-directories.
-->
<!-- <DirBuildBin>$(DirBuild)\bin</DirBuildBin> -->
<!--
The directory where the current binaries are placed after being generated.
Note that $(Platform) and $(Configuration) do not have to be defined in this settings file. They may be provided
externally as long as they are provided before the settings file is loaded!
-->
<!-- <DirBuildBinPlatformConfig>$([System.IO.Path]::GetFullPath('$(DirBuildBin)\$(PlatformWithoutSpaces)\$(Configuration)'))</DirBuildBinPlatformConfig> -->
<!-- The directory that will contain all the generated artifacts during the build process -->
<!-- <DirBuildDeploy>$(DirBuild)\deploy</DirBuildDeploy> -->
<!-- The directory that will contain all the documentation files which are generated during the build process -->
<!-- <DirBuildDoc>$(DirBuildDeploy)\doc</DirBuildDoc> -->
<!-- The directory that will contain all the generated build logs during the build process -->
<!-- <DirBuildLogs>$(DirBuild)\logs</DirBuildLogs> -->
<!-- The directory that will contain the reports generated by OpenCover and ReportGenerator describing the coverage of the unit tests. -->
<!-- <DirReportGeneratorOutput>$(DirBuildLogs)\coverage</DirReportGeneratorOutput> -->
<!-- The directory that will contain all the temporary files needed during the build process -->
<!-- <DirBuildTemp>$(DirBuild)\temp</DirBuildTemp> -->
<DirBuildTempCookbooks>$(DirBuildTemp)\cookbooks</DirBuildTempCookbooks>
<DirBuildTempIso>$(DirBuildTemp)\iso</DirBuildTempIso>
<DirBuildTempScripts>$(DirBuildTemp)\scripts</DirBuildTempScripts>
<DirBuildTempBuildPacker>$(DirBuildTemp)\build</DirBuildTempBuildPacker>
<DirBuildTempTestsIntegrationPacker>$(DirBuildTemp)\tests\integration\packer</DirBuildTempTestsIntegrationPacker>
<DirBuildTempTestsIntegrationPester>$(DirBuildTemp)\tests\integration\pester</DirBuildTempTestsIntegrationPester>
<!-- The directory that will contain all the test files generated during the test process -->
<!-- <DirBuildTest>$(DirBuild)\tests</DirBuildTest> -->
<!-- The directory that contains all the NuGet packages for the project -->
<!-- <DirPackages>$(DirWorkspace)\packages</DirPackages> -->
<!-- The directory that contains the source files for the project -->
<!-- <DirSrc>$(DirWorkspace)\src</DirSrc> -->
<DirSrcCookbooks>$(DirSrc)\cookbooks</DirSrcCookbooks>
<DirSrcPacker>$(DirSrc)\packer</DirSrcPacker>
<!-- The directory that contains the template files for the project -->
<!-- <DirTemplates>$(DirWorkspace)\templates</DirTemplates> -->
<!-- The directory that contains all the test files for the project -->
<!-- <DirTests>$(DirWorkspace)\tests</DirTests> -->
<DirTestsIntegration>$(DirTests)\integration</DirTestsIntegration>
<DirTestsIntegrationPacker>$(DirTestsIntegration)\packer</DirTestsIntegrationPacker>
<DirTestsIntegrationPester>$(DirTestsIntegration)\pester</DirTestsIntegrationPester>
<DirTestsIntegrationProvision>$(DirTestsIntegration)\provision</DirTestsIntegrationProvision>
</PropertyGroup>
<PropertyGroup>
<NameCookbook>base_linux</NameCookbook>
</PropertyGroup>
<!--
Workflow
-->
<PropertyGroup>
<!--
A flag that indicates whether or not the current build should assume that the GitFlow (http://nvie.com/posts/a-successful-git-branching-model/)
workflow is being used.
-->
<IsGitFlow>true</IsGitFlow>
</PropertyGroup>
<!--
**** PREPARE - NUGET RESTORE ****
-->
<ItemGroup>
<!--
<NuGetPackageFiles
Include="$(DirWorkspace)\packages.config"
Condition="Exists('$(DirWorkspace)\packages.config')" />
<NuGetPackageFiles
Include="$(DirSrc)\**\packages.config"
Exclude="$(DirSrc)\**\node_modules\**\packages.config;$(DirSrc)\**\bin\**\packages.config;$(DirSrc)\**\obj\**\packages.config" />
-->
</ItemGroup>
<!--
**** PREPARE - NPM RESTORE ****
-->
<ItemGroup>
<!--
<NpmPackageFiles
Include="$(DirWorkspace)\**\package.json"
Exclude="$(DirBuild)\**\package.json;$(DirWorkspace)\**\bin\**\package.json;$(DirWorkspace)\**\obj\**\package.json;$(DirWorkspace)\**\bower_components\**\package.json;$(DirWorkspace)\**\node_modules\**\package.json" />
-->
</ItemGroup>
<!--
**** PREPARE - BUNDLER RESTORE ****
-->
<ItemGroup Condition=" '$(ShouldLoadBundlerGemFiles)' == 'true' ">
<BundlerGemFiles
Condition=" '$(DirWorkspace)' != '' "
Include="$(DirSrcCookbooks)\**\Gemfile"
Exclude="$(DirBuild)\**\Gemfile;" />
</ItemGroup>
<!--
**** PREPARE - CHEF ****
-->
<!--
The collection of cookbooks for which the dependencies should be restored with Berkshelf
-->
<ItemGroup Condition=" '$(ShouldLoadChefCookbooksToRestore)' == 'true' ">
<ChefCookbooksToRestore Include="$(DirBuildTempCookbooks)\$(NameCookbook)" />
</ItemGroup>
<!--
**** PREPARE - MERGE ****
-->
<PropertyGroup>
<!--
The flag that indicates if the input branch is a GitFlow feature branch.
-->
<!-- <IsFeatureBranch Condition=" '$(IsGitFlow)' == 'true' ">$([System.Text.RegularExpressions.Regex]::IsMatch('$(GitBranchExpected)', '.*(feature\/).*'))</IsFeatureBranch> -->
<!--
The flag that indicates if the input branch is a GitFlow release branch.
-->
<!-- <IsReleaseBranch Condition=" '$(IsGitFlow)' == 'true' ">$([System.Text.RegularExpressions.Regex]::IsMatch('$(GitBranchExpected)', '.*(release\/).*'))</IsReleaseBranch> -->
<!--
The flag that indicates if the input branch is a GitFlow hotfix branch.
-->
<!-- <IsHotfixBranch Condition=" '$(IsGitFlow)' == 'true' ">$([System.Text.RegularExpressions.Regex]::IsMatch('$(GitBranchExpected)', '.*(hotfix\/).*'))</IsHotfixBranch> -->
</PropertyGroup>
<!--
The collection of branches that the changes should be merged to. The build will be executed on the last
merged branch, e.g. if the list is:
branch_1
branch_2
branch_3
Then the build process will merge to the branches in the given order and will finally execute the following
build steps on 'branch_3'.
If the branch should be tagged then that can be done as a separate build step.
Finally if the zip packaging step is included in the build process it will automatically zip the .git folder
so that other builds can reproduce the current workspace exactly.
Any failure during the branching process will stop the build process.
-->
<ItemGroup>
<!-- GITFLOW: If the input branch (GitBranchExpected) is a feature branch then we merge to develop -->
<!--
<BranchMergeTarget Include="develop"
Condition=" '$(IsGitFlow)' == 'true' AND '$(IsFeatureBranch)' == 'true' " />
-->
<!-- GITFLOW: If the input branch (GitBranchExpected) is a release branch then we merge to develop and master -->
<!--
<BranchMergeTarget Include="develop"
Condition=" '$(IsGitFlow)' == 'true' AND '$(IsReleaseBranch)' == 'true' " />
<BranchMergeTarget Include="master"
Condition=" '$(IsGitFlow)' == 'true' AND '$(IsReleaseBranch)' == 'true' " />
-->
<!-- GITFLOW: If the input branch (GitBranchExpected) is a hotfix branch then we merge to develop and master -->
<!--
<BranchMergeTarget Include="develop"
Condition=" '$(IsGitFlow)' == 'true' AND '$(IsHotfixBranch)' == 'true' " />
<BranchMergeTarget Include="master"
Condition=" '$(IsGitFlow)' == 'true' AND '$(IsHotfixBranch)' == 'true' " />
-->
</ItemGroup>
<!--
**** PREPARE - GENERATE FILES ****
-->
<PropertyGroup>
<!--
The full path to the system provided scripts that contain a task to generate
additional template tokens.
Each script should have a task with the same name as the file.
-->
<!-- <TemplateTokenGenerators>UNDEFINED</TemplateTokenGenerators> -->
</PropertyGroup>
<PropertyGroup>
<LinuxMajorVersion Condition=" '$(LinuxMajorVersion)' == '' ">18</LinuxMajorVersion>
<LinuxMinorVersion Condition=" '$(LinuxMinorVersion)' == '' ">04</LinuxMinorVersion>
<LinuxPatchVersion Condition=" '$(LinuxPatchVersion)' == '' ">5</LinuxPatchVersion>
</PropertyGroup>
<!--
Additional items that should be available for the template replacement.
The default template parameters, as indicated at the top of this file, are always available.
-->
<ItemGroup>
<!-- General -->
<TemplateTokens Include="ProductShortName">
<ReplacementValue>$(ProductName.Replace('.', '-').ToLower())</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="ImageMajorVersion">
<ReplacementValue>$(LinuxMajorVersion)</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="ImageMinorVersion">
<ReplacementValue>$(LinuxMinorVersion)</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="SysprepHostName">
<ReplacementValue>UbuntuTemplate_$([System.DateTime]::Now.ToString('yyyyMMdd'))</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="VersionConsulTemplate">
<ReplacementValue>0.25.2</ReplacementValue>
</TemplateTokens>
<!-- For the Packer config -->
<TemplateTokens Include="NameCookbook">
<ReplacementValue>$(NameCookbook)</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="DirSrcCookbooksJsonEscaped">
<ReplacementValue>$(DirBuildTempCookbooks.Replace('\', '/'))</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="DirVendorCookbooksJsonEscaped">
<ReplacementValue>$(DirVendorCookbooks.Replace('\', '/'))</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="DirTempJsonEscaped">
<ReplacementValue>$(DirBuildTemp.Replace('\', '/'))</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="DirDeployJsonEscaped">
<ReplacementValue>$(DirBuildDeploy.Replace('\', '/'))</ReplacementValue>
</TemplateTokens>
<TemplateTokens Include="DirTestsIntegrationProvisionJsonEscaped">
<ReplacementValue>$(DirTestsIntegrationProvision.Replace('\', '/'))</ReplacementValue>
</TemplateTokens>
</ItemGroup>
<Import
Condition="Exists('$(MSBuildThisFileDirectory)packer.azure.props') AND '$(ShouldCreateAzureImage)' == 'true' "
Project="$(MSBuildThisFileDirectory)packer.azure.props" />
<Import
Condition="Exists('$(MSBuildThisFileDirectory)packer.hyperv.props') AND '$(ShouldCreateHyperVImage)' == 'true' "
Project="$(MSBuildThisFileDirectory)packer.hyperv.props" />
<!--
*************************************
* *
* SHARED TOOLS *
* *
*************************************
-->
<!-- Overrides for the tools paths -->
<PropertyGroup>
<!--
The full path to the berkshelf application. If not defined the Gems bin directory is searched.
-->
<ToolsExternalBerkshelfPath>berks</ToolsExternalBerkshelfPath>
<!--
The full path and version of the GPG command line executable. If not defined the packages directory is searched.
-->
<ToolsExternalGpgPath>gpg</ToolsExternalGpgPath>
<!--
The full path and version to the packer command line executable. If not defined the packages directory is searched.
-->
<ToolsExternalPackerPath>UNDEFINED</ToolsExternalPackerPath>
<ToolsExternalPackerVersion>1.7.2</ToolsExternalPackerVersion>
</PropertyGroup>
<!--
*****************************************
* *
* TOOLS-OPS SPECIFIC SETTINGS *
* *
*****************************************
-->
<PropertyGroup>
<OpsConfigurationVersion>1.0</OpsConfigurationVersion>
</PropertyGroup>
<!--
Defines the minimum and maximum versions for Ops.Tools.Build which are used to grab the correct packages from
NuGet if no package is specified in the packages.config file.
-->
<PropertyGroup>
<PackageMinimumVersion Condition=" '$(PackageMinimumVersion)' == '' ">1.2.0</PackageMinimumVersion>
<PackageMaximumVersion Condition=" '$(PackageMaximumVersion)' == '' ">2.0.0</PackageMaximumVersion>
</PropertyGroup>
</Project>