iiab / iiab-admin-console

GUI (Admin Console) to configure IIAB and install content
GNU General Public License v2.0
12 stars 16 forks source link

adm cons install fails after #526 #529

Closed tim-moody closed 1 year ago

tim-moody commented 1 year ago

TASK [cmdsrv : Install speedtest-cli into virtual environment] **** fatal: [127.0.0.1]: FAILED! => {"changed": false, "cmd": ["/usr/bin/python3", "-m", "venv", "/usr/local/speedtest", "/usr/local/speedtest"], "msg": "stdout: The virtual environment was not created successfully because ensurepip is not\navailable. On Debian/Ubuntu systems, you need to install the python3-venv\npackage using the following command.\n\n apt install python3.10-venv\n\nYou may need to use sudo with that command. After installing the python3-venv\npackage, recreate your virtual environment.\n\nFailing command: ['/usr/local/speedtest/bin/python3', '-Im', 'ensurepip', '--upgrade', '--default-pip']\n\n"}

tim-moody commented 1 year ago

on Ubuntu 22.04 VM

holta commented 1 year ago

Smoke testing on RasPiOS and (some other Ubuntu @jvonau tested?) wasn't quite enough, oh dear.

Hopefully @jvonau (or anybody) can identify a clean fix.

Ref:

holta commented 1 year ago

Maybe Admin Console should also mandate python3-venv just like scripts/ansible now mandates.

Anyway that wouldn't hurt (for any/all components to declare their own dependencies, as much as is pragmatic anyway).

holta commented 1 year ago

My running assumption (@tim-moody can clarify) is that the above Ubuntu 22.04 test/fail took place with an older install of iiab/iiab...

tim-moody commented 1 year ago

correct me if I am wrong, but python3-venv is a dependency of ansible, not adm cons

Install was on vm after apt update upgrade and first install of newly pulled iiab and iiab-admin-console

holta commented 1 year ago

iiab/iiab now requires the install of python3-venv

iiab/iiab-admin-console apparently too, and probably should make this prereq explicit?

tim-moody commented 1 year ago

iiab/iiab now requires the install of python3-venv

so was it installed?

should adm cons install ansible?

tim-moody commented 1 year ago

anyway it was installed

root@iiab-kolibri:~# apt list |grep python3-venv

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

python3-venv/jammy-updates 3.10.6-1~22.04 amd64

holta commented 1 year ago

On a fresh install on Ubuntu 22.04 this won't flare up right?

If that's correct, I guess it's just a matter of hygiene preferences, i.e. if Admin Console should or should not also mandate python3-venv.

tim-moody commented 1 year ago

OK. I reran the ansible script and now the install succeeded.

jvonau commented 1 year ago

anyway it was installed

root@iiab-kolibri:~# apt list |grep python3-venv

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

python3-venv/jammy-updates 3.10.6-1~22.04 amd64

That suggest the package is not installed, should see [installed] at the end of the output.

tim-moody commented 1 year ago

right you are