Class: Google::Apis::MlV1::GoogleCloudMlV1EnvVar

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

Overview

Represents an environment variable to be made available in a container. This message is a subset of the Kubernetes EnvVar v1 core specification.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudMlV1EnvVar

Returns a new instance of GoogleCloudMlV1EnvVar.



1042
1043
1044
# File 'generated/google/apis/ml_v1/classes.rb', line 1042

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

Instance Attribute Details

#nameString

Name of the environment variable. Must be a valid C identifier and must not begin with the prefix AIP_. Corresponds to the JSON property name

Returns:

  • (String)


1026
1027
1028
# File 'generated/google/apis/ml_v1/classes.rb', line 1026

def name
  @name
end

#valueString

Value of the environment variable. Defaults to an empty string. In this field, you can reference environment variables set by AI Platform Prediction and environment variables set earlier in the same env field as where this message occurs. You cannot reference environment variables set in the Docker image. In order for environment variables to be expanded, reference them by using the following syntax: $(VARIABLE_NAME) Note that this differs from Bash variable expansion, which does not use parentheses. If a variable cannot be resolved, the reference in the input string is used unchanged. To avoid variable expansion, you can escape this syntax with $$; for example: $$(VARIABLE_NAME) Corresponds to the JSON property value

Returns:

  • (String)


1040
1041
1042
# File 'generated/google/apis/ml_v1/classes.rb', line 1040

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1047
1048
1049
1050
# File 'generated/google/apis/ml_v1/classes.rb', line 1047

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