Class: Google::Apis::CloudbuildV2::Step

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/cloudbuild_v2/classes.rb,
lib/google/apis/cloudbuild_v2/representations.rb,
lib/google/apis/cloudbuild_v2/representations.rb

Overview

Step embeds the Container type, which allows it to include fields not provided by Container.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Step

Returns a new instance of Step.



2750
2751
2752
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2750

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#argsArray<String>

Arguments to the entrypoint. Corresponds to the JSON property args

Returns:

  • (Array<String>)


2687
2688
2689
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2687

def args
  @args
end

#commandArray<String>

Entrypoint array. Corresponds to the JSON property command

Returns:

  • (Array<String>)


2692
2693
2694
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2692

def command
  @command
end

#envArray<Google::Apis::CloudbuildV2::EnvVar>

List of environment variables to set in the container. Corresponds to the JSON property env



2697
2698
2699
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2697

def env
  @env
end

#imageString

Docker image name. Corresponds to the JSON property image

Returns:

  • (String)


2702
2703
2704
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2702

def image
  @image
end

#nameString

Name of the container specified as a DNS_LABEL. Corresponds to the JSON property name

Returns:

  • (String)


2707
2708
2709
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2707

def name
  @name
end

#on_errorString

Optional. OnError defines the exiting behavior on error can be set to [ continue | stopAndFail ] Corresponds to the JSON property onError

Returns:

  • (String)


2713
2714
2715
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2713

def on_error
  @on_error
end

#paramsArray<Google::Apis::CloudbuildV2::Param>

Optional. Optional parameters passed to the StepAction. Corresponds to the JSON property params



2718
2719
2720
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2718

def params
  @params
end

#refGoogle::Apis::CloudbuildV2::StepRef

A reference to a remote Step, i.e. a StepAction. Corresponds to the JSON property ref



2723
2724
2725
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2723

def ref
  @ref
end

#scriptString

The contents of an executable file to execute. Corresponds to the JSON property script

Returns:

  • (String)


2728
2729
2730
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2728

def script
  @script
end

#security_contextGoogle::Apis::CloudbuildV2::SecurityContext

Security options the container should be run with. Corresponds to the JSON property securityContext



2733
2734
2735
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2733

def security_context
  @security_context
end

#timeoutString

Time after which the Step times out. Defaults to never. Corresponds to the JSON property timeout

Returns:

  • (String)


2738
2739
2740
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2738

def timeout
  @timeout
end

#volume_mountsArray<Google::Apis::CloudbuildV2::VolumeMount>

Pod volumes to mount into the container's filesystem. Corresponds to the JSON property volumeMounts



2743
2744
2745
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2743

def volume_mounts
  @volume_mounts
end

#working_dirString

Container's working directory. Corresponds to the JSON property workingDir

Returns:

  • (String)


2748
2749
2750
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2748

def working_dir
  @working_dir
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2755

def update!(**args)
  @args = args[:args] if args.key?(:args)
  @command = args[:command] if args.key?(:command)
  @env = args[:env] if args.key?(:env)
  @image = args[:image] if args.key?(:image)
  @name = args[:name] if args.key?(:name)
  @on_error = args[:on_error] if args.key?(:on_error)
  @params = args[:params] if args.key?(:params)
  @ref = args[:ref] if args.key?(:ref)
  @script = args[:script] if args.key?(:script)
  @security_context = args[:security_context] if args.key?(:security_context)
  @timeout = args[:timeout] if args.key?(:timeout)
  @volume_mounts = args[:volume_mounts] if args.key?(:volume_mounts)
  @working_dir = args[:working_dir] if args.key?(:working_dir)
end