mirror of
https://github.com/geerlingguy/ansible-role-pip.git
synced 2025-02-21 01:51:41 +01:00
Some additional work on role tests. All blind on an airplane, wheeee.
This commit is contained in:
parent
5640fffb6e
commit
2f3dc7446d
@ -20,8 +20,9 @@ script:
|
||||
# Run tests.
|
||||
- ${PWD}/tests/test.sh
|
||||
|
||||
# Test whether Docker is running correctly (Dockerception!).
|
||||
- docker exec --tty ${container_id} docker run hello-world
|
||||
# Test whether docker-py is installed at the specified version.
|
||||
- docker exec --tty ${container_id} pip list installed | grep -e '^ipaddress.*1\.0\.18.*$'
|
||||
- docker exec --tty ${container_id} pip list installed | grep '^colorama'
|
||||
|
||||
notifications:
|
||||
webhooks: https://galaxy.ansible.com/api/v1/notifications/
|
||||
|
@ -17,11 +17,14 @@ Available variables are listed below, along with default values (see `defaults/m
|
||||
A list of packages to install with pip. Examples below:
|
||||
|
||||
pip_install_packages:
|
||||
# Specify a name and version.
|
||||
# Specify names and versions.
|
||||
- name: docker-py
|
||||
version: 1.2.3
|
||||
# Or specify a package by itself.
|
||||
version: "1.2.3"
|
||||
- name: awscli
|
||||
version: "1.11.91"
|
||||
# Or specify bare packages to get the latest release.
|
||||
- docker-py
|
||||
- awscli
|
||||
|
||||
## Dependencies
|
||||
|
||||
|
@ -1,6 +1,14 @@
|
||||
---
|
||||
- hosts: all
|
||||
|
||||
vars:
|
||||
pip_install_packages:
|
||||
# Test installing a specific version of a package.
|
||||
- name: ipaddress
|
||||
version: "1.0.18"
|
||||
# Test installing a package by name.
|
||||
- colorama
|
||||
|
||||
pre_tasks:
|
||||
- name: Update apt cache.
|
||||
apt: update_cache=yes cache_valid_time=600
|
||||
|
Loading…
Reference in New Issue
Block a user