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

installer.sh:10 usage of uname broken on MacOS / Apple Silicon #69

Open
DrewMcArthur opened this issue Jun 22, 2024 · 2 comments
Open

Comments

@DrewMcArthur
Copy link

Running the installer script locally (for testing some things, not for real hosting) on an M2 MacBook, and getting this

uname: illegal option -- -
usage: uname [-amnoprsv]
installer.sh: line 11: lsb_release: command not found
installer.sh: line 12: lsb_release: command not found
ERROR: Sorry, only x86_64 and aarch64/arm64 are supported. Exiting...
Usage:
sudo bash installer.sh

Please try again.

This is because of line 10 in installer.sh, which is

PLATFORM="$(uname --hardware-platform || true)"

This yields

$ PLATFORM="$(uname --hardware-platform || true)"

uname: illegal option -- -
usage: uname [-amnoprsv]
$ echo $PLATFORM

$ 

--hardware-platform isn't an option supported by the uname on macs, i guess? but uname -m returns what you're expecting, which is arm64. So replacing that line with

PLATFORM="$(uname --hardware-platform || uname -m || true)"

still outputs the illegal option -- - lines, but sets the $PLATFORM variable correctly, allowing the script to continue.

@DrewMcArthur
Copy link
Author

of course, the next lines (11 & 12) expect the platform to be debian, so this probably doesn't matter too much, hah. is there any specific reason I can't run a PDS locally on my mac, or in a docker image? just not supported? thanks!

@bnewbold
Copy link
Contributor

You are totally welcome to run the PDS on a mac! Many of the core developers use macs for development (though I do not myself). I don't think there are too many quirks or differences. It's just docker under the hood.

For the "distribution" that we support in this repo, however, we only support a very specific and limited setup, intentionally. We don't have the technical bandwidth to support many similar-but-slightly-different setups (like FreeBSD, other linux distros, kubernetes, nomad, podman, arm64, etc, etc). In the long run, the way to have things run on many platforms will probably be to have community folks contribute write blog posts or HOWTOs/guides and have those show up in google searches!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants