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_type ⇒ Object

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

#color ⇒ Object

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

#fork ⇒ Object

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_path ⇒ Object

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

#makeflags ⇒ Object

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

#only ⇒ Object

Returns the value of attribute only

Returns:

  • (Object) —

    the current value of only



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

def only
  @only
end

#prune ⇒ Object

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

#reconcile ⇒ Object

Returns the value of attribute reconcile

Returns:

  • (Object) —

    the current value of reconcile



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

def reconcile
  @reconcile
end

#region ⇒ Object

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_directory ⇒ Object

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_repo ⇒ Object

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

#spps ⇒ Object

Returns the value of attribute spps

Returns:

  • (Object) —

    the current value of spps



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

def spps
  @spps
end

#template_directory ⇒ Object

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_overrides ⇒ Object

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)


25
26
27
28
29
30
31
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 25

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

#prune? ⇒ Boolean

Returns:

  • (Boolean)


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

def prune?
  !!prune
end

#reconcile? ⇒ Boolean

Returns:

  • (Boolean)


37
38
39
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 37

def reconcile?
  !!reconcile
end

#render_files? ⇒ Boolean

Returns:

  • (Boolean)


41
42
43
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 41

def render_files?
  true
end

#valid? ⇒ Boolean

Returns:

  • (Boolean)


21
22
23
# File 'lib/kubernetes_template_rendering/cli_arguments.rb', line 21

def valid?
  rendered_directory && template_directory
end