Class: KubernetesTemplateRendering::CLIArguments

Inherits:
Struct
  • Object
show all
Defined in:
lib/kubernetes_template_rendering/cli_arguments.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#cluster_typeObject

Returns the value of attribute cluster_type

Returns:

  • (Object)

    the current value of cluster_type



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def cluster_type
  @cluster_type
end

#colorObject

Returns the value of attribute color

Returns:

  • (Object)

    the current value of color



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def color
  @color
end

#forkObject

Returns the value of attribute fork

Returns:

  • (Object)

    the current value of fork



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def fork
  @fork
end

#jsonnet_library_pathObject

Returns the value of attribute jsonnet_library_path

Returns:

  • (Object)

    the current value of jsonnet_library_path



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def jsonnet_library_path
  @jsonnet_library_path
end

#makeflagsObject

Returns the value of attribute makeflags

Returns:

  • (Object)

    the current value of makeflags



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def makeflags
  @makeflags
end

#pruneObject

Returns the value of attribute prune

Returns:

  • (Object)

    the current value of prune



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def prune
  @prune
end

#regionObject

Returns the value of attribute region

Returns:

  • (Object)

    the current value of region



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def region
  @region
end

#rendered_directoryObject

Returns the value of attribute rendered_directory

Returns:

  • (Object)

    the current value of rendered_directory



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def rendered_directory
  @rendered_directory
end

#source_repoObject

Returns the value of attribute source_repo

Returns:

  • (Object)

    the current value of source_repo



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def source_repo
  @source_repo
end

#template_directoryObject

Returns the value of attribute template_directory

Returns:

  • (Object)

    the current value of template_directory



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def template_directory
  @template_directory
end

#variable_overridesObject

Returns the value of attribute variable_overrides

Returns:

  • (Object)

    the current value of variable_overrides



4
5
6
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 4

def variable_overrides
  @variable_overrides
end

Instance Method Details

#fork?Boolean

Returns:

  • (Boolean)


22
23
24
25
26
27
28
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 22

def fork?
  if fork.nil?
    makeflags&.include?('-j')
  else
    fork
  end
end

#prune?Boolean

Returns:

  • (Boolean)


30
31
32
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 30

def prune?
  !!prune
end

#render_files?Boolean

Returns:

  • (Boolean)


34
35
36
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 34

def render_files?
  true
end

#valid?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 18

def valid?
  rendered_directory && template_directory
end