11package Deploy
22
33import jetbrains.buildServer.configs.kotlin.*
4+ import jetbrains.buildServer.configs.kotlin.buildFeatures.dockerSupport
5+ import jetbrains.buildServer.configs.kotlin.buildSteps.ScriptBuildStep
46import jetbrains.buildServer.configs.kotlin.buildSteps.powerShell
57import jetbrains.buildServer.configs.kotlin.buildSteps.script
68import jetbrains.buildServer.configs.kotlin.triggers.vcs
@@ -42,11 +44,19 @@ object BuildPackage : BuildType({
4244 pixi run --environment default --frozen python -m build
4345 """ .trimIndent()
4446 formatStderrAsError = true
47+ dockerImage = " %DockerContainer%:%DockerVersion%"
48+ dockerImagePlatform = ScriptBuildStep .ImagePlatform .Windows
49+ dockerRunParameters = """ --cpus=4 --memory=16g"""
50+ dockerPull = true
4551 }
4652 }
4753
48- requirements {
49- equals("env.OS ", "Windows_NT ")
54+ features {
55+ dockerSupport {
56+ loginToRegistry = on {
57+ dockerRegistryId = " PROJECT_EXT_134"
58+ }
59+ }
5060 }
5161})
5262
@@ -72,11 +82,15 @@ object BuildPages : BuildType({
7282 name = " Build documentation"
7383 workingDir = " imod-python"
7484 scriptContent = """
75- set Path=% system.teamcity.build.checkoutDir%\modflow6;%env.Path%
85+ SET PATH=%%PATH%%;% system.teamcity.build.checkoutDir%\modflow6
7686
7787 pixi run --environment default --frozen docs
7888 """ .trimIndent()
7989 formatStderrAsError = true
90+ dockerImage = " %DockerContainer%:%DockerVersion%"
91+ dockerImagePlatform = ScriptBuildStep .ImagePlatform .Windows
92+ dockerRunParameters = """ --cpus=8 --memory=32g"""
93+ dockerPull = true
8094 }
8195 }
8296
@@ -105,8 +119,12 @@ object BuildPages : BuildType({
105119 }
106120 }
107121
108- requirements {
109- equals("env.OS ", "Windows_NT ")
122+ features {
123+ dockerSupport {
124+ loginToRegistry = on {
125+ dockerRegistryId = " PROJECT_EXT_134"
126+ }
127+ }
110128 }
111129})
112130
@@ -147,15 +165,23 @@ object CreateGitHubRelease : BuildType({
147165 pixi run --environment default --frozen gh release create ${' $' } tag --verify-tag --notes "See https://deltares.github.io/imod-python/api/changelog.html"
148166 """ .trimIndent()
149167 }
168+ param("plugin.docker.imagePlatform", "windows")
169+ param("plugin.docker.pull.enabled", "true")
170+ param("plugin.docker.imageId", "%DockerContainer %:%DockerVersion %")
171+ param("plugin.docker.run.parameters", "--cpus=4 --memory=16g")
150172 }
151173 }
152174
153175 failureConditions {
154176 errorMessage = true
155177 }
156178
157- requirements {
158- equals("env.OS ", "Windows_NT ")
179+ features {
180+ dockerSupport {
181+ loginToRegistry = on {
182+ dockerRegistryId = " PROJECT_EXT_134"
183+ }
184+ }
159185 }
160186})
161187
@@ -188,6 +214,10 @@ object DeployPackage : BuildType({
188214 pixi run --frozen twine check ../dist/*
189215 pixi run --frozen twine upload ../dist/*
190216 """ .trimIndent()
217+ dockerImage = " %DockerContainer%:%DockerVersion%"
218+ dockerImagePlatform = ScriptBuildStep .ImagePlatform .Windows
219+ dockerRunParameters = """ --cpus=4 --memory=16g"""
220+ dockerPull = true
191221 }
192222 }
193223
@@ -203,8 +233,12 @@ object DeployPackage : BuildType({
203233 }
204234 }
205235
206- requirements {
207- equals("env.OS ", "Windows_NT ")
236+ features {
237+ dockerSupport {
238+ loginToRegistry = on {
239+ dockerRegistryId = " PROJECT_EXT_134"
240+ }
241+ }
208242 }
209243})
210244
@@ -260,6 +294,10 @@ object DeployPages : BuildType({
260294 git push origin gh-pages
261295 """ .trimIndent()
262296 formatStderrAsError = true
297+ dockerImage = " %DockerContainer%:%DockerVersion%"
298+ dockerImagePlatform = ScriptBuildStep .ImagePlatform .Windows
299+ dockerRunParameters = """ --cpus=4 --memory=16g"""
300+ dockerPull = true
263301 }
264302 }
265303
@@ -276,8 +314,12 @@ object DeployPages : BuildType({
276314 }
277315 }
278316
279- requirements {
280- equals("env.OS ", "Windows_NT ")
317+ features {
318+ dockerSupport {
319+ loginToRegistry = on {
320+ dockerRegistryId = " PROJECT_EXT_134"
321+ }
322+ }
281323 }
282324})
283325
0 commit comments