Closed Bug 1466535 Opened 6 years ago Closed 6 years ago

Install python3 on OSX generic-worker hosts

Categories

(Infrastructure & Operations :: RelOps: Puppet, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: ahal, Unassigned)

References

Details

Attachments

(2 files)

+++ This bug was initially created as a clone of Bug #1436767 +++

I'm trying to get run-task [1] based tasks working with taskcluster's generic-worker. But the OSX hosts don't have python3 installed.

We'll need at least python 3.5+, though I assume 3.6 would be better.

[1] https://searchfox.org/mozilla-central/source/taskcluster/docker/recipes/run-task
Python 3.6 was installed on our OSX machines in bug 1451106.
[root@t-yosemite-r7-380.test.releng.mdc1.mozilla.com ~]# which python3.6
/usr/local/bin/python3.6
I don't have a loaner so have been try debugging, but here `which python3` returns 1:
https://taskcluster-artifacts.net/dFL_PhP4QwmcRy0SuT1CzQ/0/public/logs/live_backing.log

And in this push, `ls /usr/local/bin` has no python3 in it:
https://treeherder.mozilla.org/logviewer.html#?job_id=181718941&repo=try

Is it possible this is a different pool?
ahal: can you try please pyhon3.6?
https://taskcluster-artifacts.net/bAXi6dzCRduA0qfqpw8lGQ/0/public/logs/live_backing.log

That push runs:
- ls /tools
- ls /usr/local/bin
- which python3.6

All three show no sign of python3.
(In reply to Dragos Crisan [:dragrom] from comment #2)
> [root@t-yosemite-r7-380.test.releng.mdc1.mozilla.com ~]# which python3.6
> /usr/local/bin/python3.6

I believe these tasks are running as the cltbld user for some reason (at least the commands are run from /home/cltbld). Maybe python 3 was only installed for root?

It's possible that the solution here is to run these tasks with root, but I think that will require a change to the taskcluster worker that is beyond my area of expertise.
Hey :dragrom,

Could you check whether python3 is installed for the cltbld user? Thanks!
Flags: needinfo?(dcrisan)
Any updates here? This is becoming higher priority as more people are starting to need bug 1436037.
looks like python 3.6 was not installed on OSX workers (created the class to install, but not added include in worker.pp). I installed python3.6 on staging workers. To find this workers, please see: https://tools.taskcluster.net/provisioners/releng-hardware/worker-types/gecko-t-osx-1010-beta

The worker type for this workers is: gecko-t-osx-1010-beta.
O this workers, python3 is installed and visible for cltbld user:

[cltbld@t-yosemite-r7-101.test.releng.mdc2.mozilla.com ~]$ which python3.6
/usr/local/bin/python3.6

I also created a PR to include the python3 package on the workers
Flags: needinfo?(dcrisan)
Install python3 on OSX generic worker
Attachment #8995202 - Flags: review?(jwatkins)
Attachment #8995202 - Flags: review?(dhouse)
Does `which python3` yield /usr/local/bin/python3 and is that file a symlink or copy of /usr/local/bin/python3.6?
[root@t-yosemite-r7-101.test.releng.mdc2.mozilla.com tools]# which python3
[root@t-yosemite-r7-101.test.releng.mdc2.mozilla.com tools]# which python3.6
/usr/local/bin/python3.6
[root@t-yosemite-r7-101.test.releng.mdc2.mozilla.com tools]# ls -l /usr/local/bin/python3.6
lrwxr-xr-x  1 root  wheel  29 Jul 26 07:23 /usr/local/bin/python3.6 -> /tools/python36/bin/python3.6
[root@t-yosemite-r7-101.test.releng.mdc2.mozilla.com tools]# ls -l /tools/python36/bin/python3.6
-rwxr-xr-x  2 root  wheel  9420 Apr 16 05:55 /tools/python36/bin/python3.6
[root@t-yosemite-r7-101.test.releng.mdc2.mozilla.com tools]# /tools/python36/bin/python3.6 -V
Python 3.6.5
[root@t-yosemite-r7-101.test.releng.mdc2.mozilla.com tools]# ls -l /usr/local/bin/python3
ls: /usr/local/bin/python3: No such file or directory


In addition to including the python36 package in the toplevel worker class, it also looks like we need to add a symlink for /usr/local/bin/python3 -> /tools/python36/bin/python3.6
Comment on attachment 8995202 [details] [review]
Install python3 on OSX generic worker

r+ and merged
Attachment #8995202 - Flags: review?(jwatkins) → review+
Add a symlink for /usr/local/bin/python3 -> /tools/python36/bin/python3.6
Because we are in the migration process from taskcluster-worker to generic-worker I added the case entry for Ubuntu, to avoid the error message: Cannot install on Ubuntu, when run puppet on Ubuntu machines
Added python3 information, to avoid error: $python3 must be defined in this manifest file when run puppet on Ubuntu machines
Python3 installation on Ubuntu machines will be part os other bug
Attachment #8995491 - Flags: review?(jwatkins)
Attachment #8995491 - Flags: review?(dhouse)
[cltbld@t-yosemite-r7-101.test.releng.mdc2.mozilla.com ~]$ which python3
/usr/local/bin/python3
Attachment #8995491 - Flags: review?(jwatkins) → review+
Attachment #8995202 - Flags: review?(dhouse) → review+
Attachment #8995491 - Flags: review?(dhouse) → review+
Can this bug be closed?
Flags: needinfo?(dcrisan)
This bug can be closed. I closed it.
Status: NEW → RESOLVED
Closed: 6 years ago
Flags: needinfo?(dcrisan)
Resolution: --- → FIXED
See Also: → 1507488
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: