Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

We no longer need to install python on Ubuntu 18.04 #1403

Open
dannylamb opened this issue Jan 20, 2020 · 4 comments
Open

We no longer need to install python on Ubuntu 18.04 #1403

dannylamb opened this issue Jan 20, 2020 · 4 comments
Labels
Subject: Ansible Playbook Related to the maintenance and upkeep associated with an Ansible Playbook for Islandora. Always also
Milestone

Comments

@dannylamb
Copy link
Contributor

Ubuntu 18.04 ships with python 3, so instead of installing python 2, we can set ansible_python_interpreter=/usr/bin/python3 in our host file if using Ubuntu.

@whikloj
Copy link
Member

whikloj commented Jan 20, 2020

We still allow people to specify other versions so we should either restrict the base boxes allowed or make the check of ubuntu versions decide on this action.

@dannylamb
Copy link
Contributor Author

Eureka:

In bootstrap.yml we do this to ensure python

    - name: install python
      raw: test -e /usr/bin/python || (apt-get update; apt-get install -y python;)
      register: output
      changed_when:
        - output.stdout != ""
        - output.stdout != "\r\n"
      when: islandora_distro|default('') is match("ubuntu/")

which leads to it being skipped when the playbook is run

TASK [install python] ************************************************************************************************************************
Wednesday 22 January 2020  15:19:30 -0400 (0:00:00.078)       0:00:00.078 ***** 
skipping: [default]

because I'm running ansible-playbook manually and not using Vagrant, so islandora_distro is not defined 😅

I'll confirm by adding that in with -e next time I cycle these boxes.

@dannylamb
Copy link
Contributor Author

This is indeed user error 😰 I mean, we still have python3 by default and aren't using it, but i'm content to live with the consistency of python between ubuntu and centos.

@whikloj
Copy link
Member

whikloj commented Jan 22, 2020

No this is still an issue. This is the reason that when I tried to build a playbook it froze at this step. Changing this step from

raw: test -e /usr/bin/python || (apt-get update; apt-get install -y python;)

to

raw: test -e /usr/bin/python || (apt-get update; apt-get install -y python3;)

fixed it. So I personally need this fixed.

@dannylamb dannylamb reopened this Jan 22, 2020
@dannylamb dannylamb added this to the 1.1.0 milestone Jan 29, 2020
@kstapelfeldt kstapelfeldt added Subject: Ansible Playbook Related to the maintenance and upkeep associated with an Ansible Playbook for Islandora. Always also and removed Ansible labels Sep 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Subject: Ansible Playbook Related to the maintenance and upkeep associated with an Ansible Playbook for Islandora. Always also
Projects
Development

No branches or pull requests

4 participants