Class: Google::Apis::RunV2::GoogleCloudRunV2SourceFile

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

Overview

Source file.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRunV2SourceFile

Returns a new instance of GoogleCloudRunV2SourceFile.



3396
3397
3398
# File 'lib/google/apis/run_v2/classes.rb', line 3396

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

Instance Attribute Details

#contentString

Required. Input only. Represents the exact, literal, and complete source code of the file. Placeholders like ... or comments such as # [rest of code] should NEVER be used as omission. Every character in this field will be built into the final container. Any omission will result in a broken application. Corresponds to the JSON property content

Returns:

  • (String)


3385
3386
3387
# File 'lib/google/apis/run_v2/classes.rb', line 3385

def content
  @content
end

#filenameString

Required. Input only. The file name for the source code. e.g., "index.js" or "node_modules/dependency.js". The filename must be less than 255 characters and cannot contain .., ./, //, or end with a /. Cloud Run will place the files in the container subdirectories, please use relative path to access the file. Corresponds to the JSON property filename

Returns:

  • (String)


3394
3395
3396
# File 'lib/google/apis/run_v2/classes.rb', line 3394

def filename
  @filename
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3401
3402
3403
3404
# File 'lib/google/apis/run_v2/classes.rb', line 3401

def update!(**args)
  @content = args[:content] if args.key?(:content)
  @filename = args[:filename] if args.key?(:filename)
end