https://github.com/jasonheecs/ansible-ubuntu-python-raw
An ansible role that gets Ansible to work on Ubuntu machines that do not have Python pre-installed
https://github.com/jasonheecs/ansible-ubuntu-python-raw
ansible ansible-role python test-kitchen-ansible ubuntu
Last synced: 3 months ago
JSON representation
An ansible role that gets Ansible to work on Ubuntu machines that do not have Python pre-installed
- Host: GitHub
- URL: https://github.com/jasonheecs/ansible-ubuntu-python-raw
- Owner: jasonheecs
- License: mit
- Created: 2018-06-11T11:23:35.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-06-12T10:13:54.000Z (about 8 years ago)
- Last Synced: 2025-02-10T03:28:53.314Z (over 1 year ago)
- Topics: ansible, ansible-role, python, test-kitchen-ansible, ubuntu
- Language: Ruby
- Homepage:
- Size: 10.7 KB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Ansible Role: Install Python on Ubuntu machines that do not have Python pre-installed
=========
[![Build Status][travis-badge]][travis-link]
[![Galaxy Role][role-badge]][galaxy-link]
An ansible role that gets Ansible to work on bare Ubuntu machines that do not have Python pre-installed. It checks if python is installed, if not, it installs it via the [raw](https://docs.ansible.com/ansible/latest/modules/raw_module.html) module.
Requirements
------------
None.
Installation
------------
`ansible-galaxy install jasonheecs.ubuntu-python-raw`
Role Variables
--------------
Available variables are listed below, along with default values (see defaults/main.yml):
```yaml
python_version: 3
```
Dependencies
------------
None
Example Playbook
----------------
```yaml
- name: Setup
hosts: all
become: yes
gather_facts: false # You must disable the gather of facts for this role to work as intended
roles:
- { role: jasonheecs.ubuntu-python-raw }
```
Tests
---------------
Testing is done via [Test Kitchen](https://github.com/test-kitchen/test-kitchen), [Kitchen Ansible](https://github.com/neillturner/kitchen-ansible) and [Kitchen Docker](https://github.com/test-kitchen/kitchen-docker)
To run the tests, make sure [Ruby](https://www.ruby-lang.org/en/documentation/installation/) and [Docker](https://docs.docker.com/installation/#installation) are installed and run the following:
```
gem install bundler && bundle exec kitchen test
```
Refer to the [travis.yml](.travis.yml) file and [Travis build logs][travis-link] for details on the test build process and expected outputs.
Supported Platforms
-------
This ansible role has been tested against the following platforms:
- Ubuntu 18.04
- Ubuntu 16.04
- Ubuntu 14.04
License
-------
MIT
Author Information
------------------
[Jason Hee](https://jasonhee.com)
[galaxy-link]: https://galaxy.ansible.com/jasonheecs/ubuntu-python-raw/
[role-badge]: https://img.shields.io/ansible/role/26273.svg
[travis-badge]: https://travis-ci.com/jasonheecs/ansible-ubuntu-python-raw.svg?branch=master
[travis-link]: https://travis-ci.com/jasonheecs/ansible-ubuntu-python-raw