canonical / microk8s

MicroK8s is a small, fast, single-package Kubernetes for datacenters and the edge.
https://microk8s.io
Apache License 2.0
8.51k stars 772 forks source link

MicroK8s Homebrew installation fails on macOS Sonoma 14.5 #4580

Open octameter opened 3 months ago

octameter commented 3 months ago

Summary

Tried to install microk8s according to the instruction: https://microk8s.io/#install-microk8s using: brew install ubuntu/microk8s/microk8s on a MacBook Pro M2, 24 GB, Sonoma 14.5. Homebrew:

cc@MacBook-Pro ~ % brew install ubuntu/microk8s/microk8s ==> Fetching ubuntu/microk8s/microk8s ==> Downloading https://github.com/canonical/microk8s/archive/refs/tags/installer-v2.3.4.tar.gz Already downloaded: /Users/dimi/Library/Caches/Homebrew/downloads/281c9d82705923ca3136ff18904081c5aa47bd1c6cd754f6562810a7d68f9af0--microk8s-installer-v2.3.4.tar.gz ==> Installing microk8s from ubuntu/microk8s ==> python3 -m venv --system-site-packages --without-pip /usr/local/Cellar/microk8s/2.3.4/libexec ==> python3 -m pip --python=/usr/local/Cellar/microk8s/2.3.4/libexec/bin/python install urllib3==1.26.5 click==7.1.2 progressbar33==2.4 psutil==5.9.0 requests==2.25.1 requests_unixs Last 15 lines from /Users/dimi/Library/Logs/Homebrew/microk8s/02.python3: click==7.1.2 progressbar33==2.4 psutil==5.9.0 requests==2.25.1 requests_unixsocket==0.1.5 pysha3==1.0.2; python_version < '3.6' simplejson==3.8.2 toml==0.10.0 certifi==2023.7.22 chardet==3.0.4 idna==2.7 pyinstaller https://pyyaml.org/download/pyyaml/PyYAML-5.3.1-cp38-cp38-win_amd64.whl; sys_platform == 'win32'

/usr/local/opt/python@3.12/bin/python3.12: No module named pip

If reporting this issue please do so at (not Homebrew/brew or Homebrew/homebrew-core): https://github.com/ubuntu/homebrew-microk8s/issues

What Should Happen Instead?

Should complete without errors, to be ready for microk8s install

Reproduction Steps

Terminal > brew install ubuntu/microk8s/microk8s Homebrew was updated and upgraded befor installation attempt

Introspection Report

does not apply

Can you suggest a fix?

none

Are you interested in contributing with a fix?

no

carvido1 commented 3 months ago

Hello @octameter .

Have you tried

curl https://bootstrap.pypa.io/get-pip.py | python3

before the microk8s installation ?

octameter commented 3 months ago

Hello @carvido1

Thanks for your reply. I have tried to install pip using the usr/local/opt/python@3.12/bin/python3.12 and just straight in the Terminal with no success:

xx@MacBook-Pro ~ % cd /usr/local/opt/python@3.12/bin/ xx@MacBook-Pro bin % curl https://bootstrap.pypa.io/get-pip.py | python3.12 % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2224k 100 2224k 0 0 3029k 0 --:--:-- --:--:-- --:--:-- 3026k Collecting pip Using cached pip-24.1.2-py3-none-any.whl.metadata (3.6 kB) Collecting wheel Using cached wheel-0.43.0-py3-none-any.whl.metadata (2.2 kB) Using cached pip-24.1.2-py3-none-any.whl (1.8 MB) Using cached wheel-0.43.0-py3-none-any.whl (65 kB) Installing collected packages: wheel, pip Attempting uninstall: pip Found existing installation: pip 24.0 Uninstalling pip-24.0: Successfully uninstalled pip-24.0 Successfully installed pip-24.1.2 wheel-0.43.0

brew install ubuntu/microk8s/microk8s -v ==> Auto-updating Homebrew... Adjust how often this is run with HOMEBREW_AUTO_UPDATE_SECS or disable with HOMEBREW_NO_AUTO_UPDATE. Hide these hints with HOMEBREW_NO_ENV_HINTS (see man brew). ==> Fetching ubuntu/microk8s/microk8s ==> Downloading https://github.com/canonical/microk8s/archive/refs/tags/installer-v2.3.4.tar.gz Already downloaded: /Users/dimi/Library/Caches/Homebrew/downloads/281c9d82705923ca3136ff18904081c5aa47bd1c6cd754f6562810a7d68f9af0--microk8s-installer-v2.3.4.tar.gz ==> Verifying checksum for '281c9d82705923ca3136ff18904081c5aa47bd1c6cd754f6562810a7d68f9af0--microk8s-installer-v2.3.4.tar.gz' ==> Installing microk8s from ubuntu/microk8s /usr/bin/env tar --extract --no-same-owner --file /Users/dimi/Library/Caches/Homebrew/downloads/281c9d82705923ca3136ff18904081c5aa47bd1c6cd754f6562810a7d68f9af0--microk8s-installer-v2.3.4.tar.gz --directory /private/tmp/homebrew-unpack20240725-29996-7dmfs2 /usr/bin/env cp -pR /private/tmp/homebrew-unpack20240725-29996-7dmfs2/microk8s-installer-v2.3.4/. /private/tmp/microk8s-20240725-29996-nm4jph/microk8s-installer-v2.3.4 ==> python3 -m venv --system-site-packages --without-pip /usr/local/Cellar/microk8s/2.3.4/libexec ==> python3 -m pip --python=/usr/local/Cellar/microk8s/2.3.4/libexec/bin/python install --verbose --no-deps --no-binary=:all: --ignore-installed --no-compile urllib3==1.26.5 click==7.1.2 progressbar33==2.4 psutil==5.9.0 requests==2.25.1 requests_unixsocket==0.1.5 pysha3==1.0.2; python_version < '3.6' simplejson==3.8.2 toml==0.10.0 certifi==2023.7.22 chardet==3.0.4 idna==2.7 pyinstaller https://pyyaml.org/download/pyyaml/PyYAML-5.3.1-cp38-cp38-win_amd64.whl; sys_platform == 'win32' /usr/local/opt/python@3.12/bin/python3.12: No module named pip

-> I wonder if it hast to do with sys_platform == 'win32'?