Class: Google::Apis::CloudbuildV2::Sidecar

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

Sidecars run alongside the Task's step containers.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Sidecar

Returns a new instance of Sidecar.



2019
2020
2021
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2019

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

Instance Attribute Details

#argsArray<String>

Arguments to the entrypoint. Corresponds to the JSON property args

Returns:

  • (Array<String>)


1977
1978
1979
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 1977

def args
  @args
end

#commandArray<String>

Entrypoint array. Corresponds to the JSON property command

Returns:

  • (Array<String>)


1982
1983
1984
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 1982

def command
  @command
end

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

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



1987
1988
1989
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 1987

def env
  @env
end

#imageString

Docker image name. Corresponds to the JSON property image

Returns:

  • (String)


1992
1993
1994
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 1992

def image
  @image
end

#nameString

Name of the Sidecar. Corresponds to the JSON property name

Returns:

  • (String)


1997
1998
1999
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 1997

def name
  @name
end

#scriptString

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

Returns:

  • (String)


2002
2003
2004
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2002

def script
  @script
end

#security_contextGoogle::Apis::CloudbuildV2::SecurityContext

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



2007
2008
2009
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2007

def security_context
  @security_context
end

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

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



2012
2013
2014
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2012

def volume_mounts
  @volume_mounts
end

#working_dirString

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

Returns:

  • (String)


2017
2018
2019
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2017

def working_dir
  @working_dir
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 2024

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)
  @script = args[:script] if args.key?(:script)
  @security_context = args[:security_context] if args.key?(:security_context)
  @volume_mounts = args[:volume_mounts] if args.key?(:volume_mounts)
  @working_dir = args[:working_dir] if args.key?(:working_dir)
end