Skip to content
This repository has been archived by the owner on Aug 29, 2023. It is now read-only.

setup.sh should verify that ignite dependencies are installed #58

Open
mflendrich opened this issue Oct 7, 2019 · 2 comments
Open

setup.sh should verify that ignite dependencies are installed #58

mflendrich opened this issue Oct 7, 2019 · 2 comments
Labels
chore Related to fix/refinement/improvement of end user or new/existing developer functionality good first issue Good for newcomers

Comments

@mflendrich
Copy link
Contributor

This is what happens if I run ./setup.sh with everything but cni (which is a dependency of ignite) installed (see the last line of the output):

💵 michal@piec (master) ~/go/src/gith/weav/wks-quickstart-firekube> ./setup.sh
• Found jk 0.3.0
• Found footloose 0.6.2
• Found ignite 0.6.1
• Found wksctl 1.1.6-862-g1bf26b84
• Creating footloose manifest
• Creating virtual machines
INFO[0000] Docker Image: weaveworks/ignite-centos:firekube-pre3 present locally 
INFO[0000] Creating machine: firekube-node0 ...         
FATA[0002] command "ignite run weaveworks/ignite-centos:firekube-pre3 --name=firekube-node0 --cpus=2 --memory=1GB --size=5GB --kernel-image=weaveworks/ignite-kernel:4.19.47 --ssh=/home/michal/go/src/github.com/weaveworks/wks-quickstart-firekube/cluster-key.pub --ports=2222:22 --ports=6443:6443 --ports=30443:30443 --ports=30080:30080" exited with "time=\"2019-10-07T22:58:44+02:00\" level=info msg=\"Created VM with ID \\\"7ffb36851667998e\\\" and name \\\"firekube-node0\\\"\"\ntime=\"2019-10-07T22:58:44+02:00\" level=fatal msg=\"[ERROR ExistingFile--opt-cni-bin-loopback]: File /opt/cni/bin/loopback, does not exist\\n[ERROR ExistingFile--opt-cni-bin-bridge]: File /opt/cni/bin/bridge, does not exist\\n\"\n": exit status 1 
🧨 [1] michal@piec (master) ~/go/src/gith/weav/wks-quickstart-firekube> 

In my case this happened because I upgraded ignite without installing cni which is a new dependency added in the version I upgraded to.

I think that we should be just as dilligent at checking deeper dependencies, or implement dependency checking in ignite.

@mflendrich mflendrich added good first issue Good for newcomers chore Related to fix/refinement/improvement of end user or new/existing developer functionality labels Oct 7, 2019
@stealthybox
Copy link
Contributor

stealthybox commented Oct 8, 2019

This output is coming from an ignite pre-flight check:

msg=\"[ERROR ExistingFile--opt-cni-bin-loopback]: File /opt/cni/bin/loopback, does not exist\\n[ERROR ExistingFile--opt-cni-bin-bridge]: File /opt/cni/bin/bridge, does not exist\\n\"\n"

Footloose is wrapping the error.

Ignite currently doesn't have an independent check command, but we have an open issue to add one.

This is a fine proposal for ./setup.sh.
We'd need to detect when ignite >= 0.6.x because CNI binary installation doesn't apply for 0.5.x.
It also requires root privileges to install these binaries as the CNI directories are not currently configurable.

I am curious how you ended up installing v0.6.1 without CNI binaries.
Is that because of the ignite release notes?
https://github.com/weaveworks/ignite/releases/tag/v0.6.1

Were you able to identify the issue and correct it quickly based off of the log message?

@mflendrich
Copy link
Contributor Author

I am curious how you ended up installing v0.6.1 without CNI binaries.
Is that because of the ignite release notes?

Yes. A "latest release" link in the output of setup.sh led me there. I followed the instructions under Trying it out / Next Steps! which only overwrite ignite and ignited.

Were you able to identify the issue and correct it quickly based off of the log message?

Yes but not immediately. The error message appeared after INFO[0000] Creating machine: firekube-node0 ... so I initially assumed that the missing file was not found within the VM.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
chore Related to fix/refinement/improvement of end user or new/existing developer functionality good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants