Closed prahal closed 1 year ago
Jira ticket: AR-1734
Note that this issue is minimal as per the log provided tip removing docker from the command still runs docker behind the scene and works.
That is ./compile.sh BOARD=helios64 BRANCH=edge BUILD_ONLY="u-boot" RELEASE=bullseye KERNEL_CONFIGURE=no BUILD_MINIMAL=yes
is fine. As is ./compile.sh BOARD=helios64 BRANCH=edge RELEASE=bullseye uboot
.
So basically not an issue. FWIW perhaps this error can be downgraded to a warning and simply ignored.
Documentation regarding docker is wrong. Probably whole section can be removed.
The error tries hard to explain what is going on... is it being ignored by user, or needs rewording?
[🐳|💥] error! [ asking for docker... inside docker. how did this happen? Tip: you don't need 'docker' to run armbian-next inside Docker; it's automatically detected and used when appropriate. ]
Maybe updating the wiki? But maybe it waits for armbian-next to be published?
As I was told that I do not need docker, when I saw the message I thought I should not use docker anymore not that I should remove docker from the compile.sh command line.
With, the wiki https://docs.armbian.com/Developer-Guide_Building-with-Docker/ telling to have docker in the compile.sh it was even more difficult to understand what was to be done, ie remove docker from compile.sh command line.
The message could be reworded to explicitly state to not pass 'docker' to the compile.sh cli.
I admit that on a later read of the message, focusing on it's automatically detected and used when appropriate. ]
lead me to try to not pass docker in the command.
The issue is with you don't need 'docker' to run armbian-next inside Docker;
.
Maybe do not pass 'docker' to compile.sh to run armbian-next inside Docker;
.
Also because 'you don't need' means that we should be able to do it even if optional. While in fact, it does not work at all if we pass 'docker' to compile.sh.
Thanks @prahal -- I think here we boil down to "docs need updating".
... when omitting "docker" from build command, build won't start on my machine because of unsupported build environment. It works with "docker-shell" and then running build command inside the container.
https://docs.armbian.com/Developer-Guide_Building-with-Docker/ -> docker-shell-interactive-mode
@praul are you on armbian-next (the current main branch or such)? Because with armbian-next, docker-shell and building inside are broken https://github.com/armbian/build/issues/5203, or at least it was a few months ago (I did not check recently). This is because the compile.sh script refuses to run as root.
With armbian-next you have to pass an argument to build only u-boot, the kernel, patch the kernel ... ie ./compiles.sh uboot <..>; ./compile.sh kernel-patch <...>; ./compile.sh kernel <...>;
The documentation on the site is for the obsolete armbian master branch (not updated since February 2023).
As today, this error is still present. I am trying to build an armbian image in a non debian distribution and failing due to the same error. I am pretty sure its a bug or mismaintain. As one tries to run the dockerized version, it fails with the same goofy "runing docker inside docker? how did this happen?" error. This is also true for the stabe v23.11 version... Also note that the documentation suggests to ADD USER TO DOCKER GROUP which is super unsafe because of known vulnerabilites that can be leveraged for privilege escalation, so no, i am not doing that.
As today, this error is still present.
Command parameters has change since. Try this - it works as expected:
./compile.sh uboot BOARD=helios64 BRANCH=edge
Logs: https://paste.armbian.com/yuzimawoxo
non debian distribution
This tool is here to make a distro for SBC. Tool works and is well auto-tested with Ubuntu Jammy. Elsewhere? It might, no warranty, no support. Supporting all distributions out there is simply impossible, far from primary mission.
I am pretty sure its a bug or mismaintain.
It is, but its yours as you are running not supported build host. But if you find and fix this problem on the way that it won't break primary build host distribution, we will merge it.
This is also true for the stabe v23.11 version.
Why would that be different in supporting distribution X?
documentation suggests
It also suggest to run this virtualised ... in case you have security concerns. In order to generate images via /dev/loop devices, we need privileged Docker access. We tried many things and failed, but if you know what we don't, improvements are always welcome.
@igorpecovnik
Thanks for the response. I was not aware of the new uboot parameter, where can i find more information about it? i will probably need to read the scripts.
As for the docker param, it doesnt work on my machine, it seems to be a bug related to systemd-nspawn
containerization.
My solution was indeed virtualization. Fully working now. I would recommend virtualizing upon any compatibility problem @ the host system.
I wont develop a solution @ code level because of the implications of the problem is not an area i feel THAT comfortable as for hacking it for a solution.
I could help at some changes at the docs entries for better explain the problem and also, aknowledge the systemd-nspawn
containafization wont work.
I am currently working on a project, so when i get more familiarized i could try to document the new parameters for the script (like uboot) that i didnt found on the docs.
Please elaborate on how is the process on contrib @ documentation level and i gladly send some pullreqs. Im asking as if you are some sort of experienced guy or a maintainer. Any hints on how to contrib help.
All being said, thanks for spend some time answering me
where can i find more information about it?
Sadly, only in the scripts / code.
how is the process on contrib @ documentation level and i gladly send some pullreqs
We are trying to make it ... join if you can.
This also: https://github.com/armbian/build/pull/6389
What happened?
While building with the latest main 8eeb9379d I cannot build with docker without it aborting this way (even from a fresh checkout):
How to reproduce?
./compile.sh docker BOARD=helios64 BRANCH=edge BUILD_ONLY="u-boot" RELEASE=bullseye KERNEL_CONFIGURE=no
Branch
main (main development branch)
On which host OS are you observing this problem?
Bullseye
Relevant log URL
https://paste.next.armbian.com/qobadodovu
Code of Conduct