Class: PoisePython::PythonProviders::Base

Inherits:
Chef::Provider
  • Object
show all
Defined in:
lib/poise_python/python_providers/base.rb

Overview

Since:

  • 1.0.0

Instance Method Summary collapse

Instance Method Details

#action_install

This method returns an undefined value.

The install action for the python_runtime resource.

Since:

  • 1.0.0



43
44
45
46
47
48
49
50
51
52
53
54
55
56
# File 'lib/poise_python/python_providers/base.rb', line 43

def action_install
  # First inner converge for the Python install.
  notifying_block do
    install_python
  end
  # Second inner converge for the support tools. This is needed because
  # we run a python command to check if venv is available.
  notifying_block do
    install_pip
    install_setuptools
    install_wheel
    install_virtualenv
  end
end

#action_uninstall

This method is abstract.

This method returns an undefined value.

The uninstall action for the python_runtime resource.

Since:

  • 1.0.0



62
63
64
65
66
# File 'lib/poise_python/python_providers/base.rb', line 62

def action_uninstall
  notifying_block do
    uninstall_python
  end
end

#python_binaryString

This method is abstract.

The path to the python binary. This is an output property.

Returns:

  • (String)

Raises:

  • (NotImplementedError)

Since:

  • 1.0.0



72
73
74
# File 'lib/poise_python/python_providers/base.rb', line 72

def python_binary
  raise NotImplementedError
end

#python_environmentHash<String, String>

The environment variables for this Python. This is an output property.

Returns:

  • (Hash<String, String>)

Since:

  • 1.0.0



79
80
81
# File 'lib/poise_python/python_providers/base.rb', line 79

def python_environment
  {}
end