Class: Google::Cloud::Batch::V1::Runnable
- Inherits:
-
Object
- Object
- Google::Cloud::Batch::V1::Runnable
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/batch/v1/task.rb
Overview
Runnable describes instructions for executing a specific script or container as part of a Task.
Defined Under Namespace
Classes: Barrier, Container, LabelsEntry, Script
Instance Attribute Summary collapse
-
#always_run ⇒ ::Boolean
By default, after a Runnable fails, no further Runnable are executed.
-
#background ⇒ ::Boolean
This flag allows a Runnable to continue running in the background while the Task executes subsequent Runnables.
-
#barrier ⇒ ::Google::Cloud::Batch::V1::Runnable::Barrier
Barrier runnable.
-
#container ⇒ ::Google::Cloud::Batch::V1::Runnable::Container
Container runnable.
-
#display_name ⇒ ::String
Optional.
-
#environment ⇒ ::Google::Cloud::Batch::V1::Environment
Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup).
-
#ignore_exit_status ⇒ ::Boolean
Normally, a non-zero exit status causes the Task to fail.
-
#labels ⇒ ::Google::Protobuf::Map{::String => ::String}
Labels for this Runnable.
-
#script ⇒ ::Google::Cloud::Batch::V1::Runnable::Script
Script runnable.
-
#timeout ⇒ ::Google::Protobuf::Duration
Timeout for this Runnable.
Instance Attribute Details
#always_run ⇒ ::Boolean
Returns By default, after a Runnable fails, no further Runnable are executed. This flag indicates that this Runnable must be run even if the Task has already failed. This is useful for Runnables that copy output files off of the VM or for debugging.
The always_run flag does not override the Task's overall max_run_duration. If the max_run_duration has expired then no further Runnables will execute, not even always_run Runnables.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#background ⇒ ::Boolean
Returns This flag allows a Runnable to continue running in the background while the Task executes subsequent Runnables. This is useful to provide services to other Runnables (or to provide debugging support tools like SSH servers).
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#barrier ⇒ ::Google::Cloud::Batch::V1::Runnable::Barrier
Returns Barrier runnable.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#container ⇒ ::Google::Cloud::Batch::V1::Runnable::Container
Returns Container runnable.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#display_name ⇒ ::String
Returns Optional. DisplayName is an optional field that can be provided by the caller. If provided, it will be used in logs and other outputs to identify the script, making it easier for users to understand the logs. If not provided the index of the runnable will be used for outputs.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#environment ⇒ ::Google::Cloud::Batch::V1::Environment
Returns Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup).
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#ignore_exit_status ⇒ ::Boolean
Returns Normally, a non-zero exit status causes the Task to fail. This flag allows execution of other Runnables to continue instead.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#labels ⇒ ::Google::Protobuf::Map{::String => ::String}
Returns Labels for this Runnable.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#script ⇒ ::Google::Cloud::Batch::V1::Runnable::Script
Returns Script runnable.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#timeout ⇒ ::Google::Protobuf::Duration
Returns Timeout for this Runnable.
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 |
# File 'proto_docs/google/cloud/batch/v1/task.rb', line 191 class Runnable include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Container runnable. # @!attribute [rw] image_uri # @return [::String] # The URI to pull the container image from. # @!attribute [rw] commands # @return [::Array<::String>] # Overrides the `CMD` specified in the container. If there is an ENTRYPOINT # (either in the container image or with the entrypoint field below) then # commands are appended as arguments to the ENTRYPOINT. # @!attribute [rw] entrypoint # @return [::String] # Overrides the `ENTRYPOINT` specified in the container. # @!attribute [rw] volumes # @return [::Array<::String>] # Volumes to mount (bind mount) from the host machine files or directories # into the container, formatted to match docker run's --volume option, # e.g. /foo:/bar, or /foo:/bar:ro # # If the `TaskSpec.Volumes` field is specified but this field is not, Batch # will mount each volume from the host machine to the container with the # same mount path by default. In this case, the default mount option for # containers will be read-only (ro) for existing persistent disks and # read-write (rw) for other volume types, regardless of the original mount # options specified in `TaskSpec.Volumes`. If you need different mount # settings, you can explicitly configure them in this field. # @!attribute [rw] options # @return [::String] # Arbitrary additional options to include in the "docker run" command when # running this container, e.g. "--network host". # @!attribute [rw] block_external_network # @return [::Boolean] # If set to true, external network access to and from container will be # blocked, containers that are with block_external_network as true can # still communicate with each other, network cannot be specified in the # `container.options` field. # @!attribute [rw] username # @return [::String] # Optional username for logging in to a docker registry. If username # matches `projects/*/secrets/*/versions/*` then Batch will read the # username from the Secret Manager. # @!attribute [rw] password # @return [::String] # Optional password for logging in to a docker registry. If password # matches `projects/*/secrets/*/versions/*` then Batch will read the # password from the Secret Manager; class Container include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Script runnable. # @!attribute [rw] path # @return [::String] # Script file path on the host VM. # # To specify an interpreter, please add a `#!<interpreter>`(also known as # [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the # first line of the file.(For example, to execute the script using bash, # `#!/bin/bash` should be the first line of the file. To execute the # script using`Python3`, `#!/usr/bin/env python3` should be the first # line of the file.) Otherwise, the file will by default be excuted by # `/bin/sh`. # @!attribute [rw] text # @return [::String] # Shell script text. # # To specify an interpreter, please add a `#!<interpreter>\n` at the # beginning of the text.(For example, to execute the script using bash, # `#!/bin/bash\n` should be added. To execute the script using`Python3`, # `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will # by default be excuted by `/bin/sh`. class Script include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Barrier runnable blocks until all tasks in a taskgroup reach it. # @!attribute [rw] name # @return [::String] # Barriers are identified by their index in runnable list. # Names are not required, but if present should be an identifier. class Barrier include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |