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

deploy-mgmt-hub.sh fails on Intel Mac #176

Open
gerardkr opened this issue Aug 26, 2024 · 1 comment
Open

deploy-mgmt-hub.sh fails on Intel Mac #176

gerardkr opened this issue Aug 26, 2024 · 1 comment

Comments

@gerardkr
Copy link

I'm trying to install the Open Horizon management hub on my Intel Mac using the command

export HZN_LISTEN_IP=192.168.xxx.xxx # this may be irrelevant
curl -sSL https://raw.githubusercontent.com/open-horizon/devops/master/mgmt-hub/deploy-mgmt-hub.sh | bash

It fails with

bash: line 672: ip: command not found

There is no "ip" command on my Mac system, but there are both "ifconfig" and "ipconfig" commands which appears to do the similar things.

Joe Pearson said:
looks like the equivalent on Mac would be ipconfig getifaddr en0 for wireless or ipconfig getifaddr en1 for ethernet

However, I believe the problem is a bit more involved.

So perhaps the best approach is to have users specify which IP address they want to use via HZN_LISTEN_IP. I tried this above but don't think it had any effect. Or perhaps you use HZN_LISTEN_IP if it is set; otherwise fall back to use Joe's suggestion. In any case, "ip" won't work for Mac.

@gerardkr
Copy link
Author

I've hacked around the "ip" command by loading HZN_LISTEN_IP directly.

The next error is running (slightly modified to run as a single command)

sudo openssl req -newkey rsa:4096 -nodes -sha256 -x509 -days +365 -out /etc/horizon/keys/horizonMgmtHubFDO.crt -subj "/C=US/ST=NY/L=New York/O=[email protected]/CN=tesseract2.local" -extensions san -config openssl-config-crap.txt

where openssl-config-crap.txt contains

[req]
distinguished_name=req
[san]
subjectAltName=192.168.5.19,DNS:localhost,DNS:agbot,DNS:exchange-api,DNS:css-api,DNS:fdo-owner-services

The result is

Error Loading extension section san
140704545656768:error:2207507C:X509 V3 routines:v2i_GENERAL_NAME_ex:missing value:crypto/x509v3/v3_alt.c:533:
140704545656768:error:22098080:X509 V3 routines:X509V3_EXT_nconf:error in extension:crypto/x509v3/v3_conf.c:47:name=subjectAltName, value=192.168.5.19,DNS:localhost,DNS:agbot,DNS:exchange-api,DNS:css-api,DNS:fdo-owner-services

I've tried to debug the issue, but haven't made any notable progress.

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

4 participants
@gerardkr and others