Skip to content

Commit 96cb57c

Browse files
authored
Add Google Batch warning when for conflicting disk image config (#5279) [ci fast]
When both boot disk image and instance template are specified, the instance template gets priority, as with many other options covered by instance templates. Warn the user in this case. This was missed in #5268. Signed-off-by: Siddhartha Bagaria <1929612+siddharthab@users.noreply.github.com>
1 parent a0bf8b4 commit 96cb57c

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

docs/google.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ process myTask {
156156

157157
:::{note}
158158
Using an instance template will overwrite the `accelerator` and `disk` directives, as well as the following Google Batch
159-
config options: `cpuPlatform`, `preemptible`, and `spot`.
159+
config options: `bootDiskImage`, `cpuPlatform`, `preemptible`, and `spot`.
160160
:::
161161

162162
To use an instance template with GPUs, you must also set the `google.batch.installGpuDrivers` config option to `true`.

plugins/nf-google/src/main/nextflow/cloud/google/batch/GoogleBatchTaskHandler.groovy

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,9 @@ class GoogleBatchTaskHandler extends TaskHandler implements FusionAwareTask {
303303
if( task.config.getDisk() )
304304
log.warn1 'Process directive `disk` ignored because an instance template was specified'
305305

306+
if( executor.config.getBootDiskImage() )
307+
log.warn1 'Config option `google.batch.bootDiskImage` ignored because an instance template was specified'
308+
306309
if( executor.config.cpuPlatform )
307310
log.warn1 'Config option `google.batch.cpuPlatform` ignored because an instance template was specified'
308311

0 commit comments

Comments
 (0)