-
Notifications
You must be signed in to change notification settings - Fork 42
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
Support for x86 (32bit and 64bit) #340
Conversation
Rouge space
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like great work to support more boards, thanks a lot! I left some small comments. The only large thing I think is left is updating docs to explain the support that is not offered, and the variety of boards that fall under it. I think that should be done in this PR.
URL="https://dl.grafana.com/oss/release/grafana_${GRAFANA_VERSION}_armel.deb"; | ||
;; | ||
armv6l) | ||
# Use old grafana - no new one available |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe have a separate GRAFANA_ARMHF_VERSION
variable to change later?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have not been able to find any other Grafana for armv6l and i dont think it will be updated.
If some one can find it please let me know
Otherwise the options are
- Not have Grafana available
- Keep it static to an old version as it is now :( (at least for now still compatible)
- Build it ourselves (any takes on building it from source :))
We can Create this as an issue if there is interest in it
PS: armv6l = Raspbery Pi 1 and Zero
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Building a binary ourselves would be the best for compatibility, but there are trust issues, since they won't be confirmed by the devs. Maybe you can contact the devs about this (make a new issue for it in the repo too), and for now we'll leave the old version? I would also some sort of warning with echo
.
;; | ||
*) | ||
echo "Unknown Arch" | ||
exit 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You use exit 0
up above for when you can't download because of i386. Does the code make any difference?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Difference is as folows:
0 will exit the script but continue executing install (we KNOW i386 is not available so just continue)
1 will stop execution the install script (Something went wrong if we dont know what ARCH it is!)
|
||
BOARD_MODEL="Unknown" | ||
BOARD_NAME="Unknown" | ||
BOARD_OS="Unknown" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these variables exported?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No.
Instead of being exported somewhere in the script then used by the modules, the function is part of a shared file and the function can be called by any module when needed to set it in their environment.
This allows each module to be run without having to run the whole script to set them and be independent.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I see, so the variables are set every time.
# Set some defaults | ||
if [[ "$ARCH" == "armv7l" ]]; then | ||
#TODO# -O2 workaround. Needs to be resolved. | ||
CJDNS_BUILD_CMD="sudo Seccomp_NO=1 CFLAGS=\"-O2 -s -static -Wall -march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard -fomit-frame-pointer -marm\" ./do" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe single quotes would make this cleaner?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe. But its a copy /paste from Prototype version1.
The whole cjdns build needs to be assessed and cleaned up Noted in #165
Grafana note added in this repo |
New board detection routine Closes #329
Added support for x86 and arm64 Closes #328
Node Exporter Closes #212 , Grafana Closes #204 and Prometheus version bump