Skip to content
This repository has been archived by the owner on Jan 30, 2024. It is now read-only.

Commit

Permalink
Add workon/virtualenvwrapper to centos
Browse files Browse the repository at this point in the history
Whatever was causing the installation problem seems to have gone away,
leaving only a minor problem that virtualenvwrapper is not installed on
CentOS so `workon pulp` didn't work.

https://pulp.plan.io/issues/4545
fixes #4545
  • Loading branch information
asmacdo committed Jun 6, 2019
1 parent 7aee1f4 commit 916ad2d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
9 changes: 8 additions & 1 deletion roles/pulp-devel/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@
register: result
until: result is succeeded

- name: Install Centos Specific Packages
package:
name:
- python-virtualenvwrapper
when: ansible_distribution == 'CentOS'

- name: Install several useful packages (Debian-specific)
package:
name:
Expand Down Expand Up @@ -129,7 +135,8 @@
template:
src: templates/venv.bashrc.j2
dest: '{{ developer_user_home }}/.bashrc.d/venv.bashrc'
when: ansible_distribution == 'Debian' or ansible_distribution == 'Fedora'
when: ansible_distribution != 'Ubuntu'


become: true
become_user: "{{ developer_user }}"
Expand Down
3 changes: 3 additions & 0 deletions roles/pulp-devel/templates/venv.bashrc.j2
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,6 @@ source /usr/bin/virtualenvwrapper-3.sh
{% if ansible_distribution == 'Debian' %}
export VIRTUALENVWRAPPER_HOOK_DIR=$HOME/.virtualenvs
{% endif %}
{% if ansible_distribution == 'CentOS' %}
source /usr/bin/virtualenvwrapper.sh
{% endif %}

0 comments on commit 916ad2d

Please sign in to comment.