build icon indicating copy to clipboard operation
build copied to clipboard

[Bug]:/usr/bin/docker: Argument list too long

Open liu2-3zhi opened this issue 1 year ago β€’ 18 comments

What happened?

🌱] Socket /run/user/1000/keyring/ssh [ SSH agent forwarding into Docker ] [🌱] Launching Docker shell [ docker-shell ] /home/zelly/摌青/armbian-build/build/lib/functions/cli/cli-docker.sh: 葌 80: /usr/bin/docker: ε‚ζ•°εˆ—θ‘¨θΏ‡ι•Ώ [πŸ’₯] Error 126 occurred in main shell [ at /home/zelly/摌青/armbian-build/build/lib/functions/cli/cli-docker.sh:80 cli_docker_run() --> lib/functions/cli/cli-docker.sh:80 armbian_cli_run_command() --> lib/functions/cli/utils-cli.sh:136 cli_entrypoint() --> lib/functions/cli/entrypoint.sh:176 main() --> ./compile.sh:50 ] [πŸ’₯] Cleaning up [ please wait for cleanups to finish ]

How to reproduce?

Use Docker to Build

Branch

main (main development branch)

On which host OS are you running the build script and observing this problem?

Ubuntu 24.04 Noble

Are you building on Windows WSL2?

  • [ ] Yes, my Ubuntu/Debian/OtherOS is running on WSL2

Relevant log URL

https://paste.armbian.com/pikunapaka

Code of Conduct

  • [ ] I agree to follow this project's Code of Conduct

liu2-3zhi avatar Jul 25 '24 11:07 liu2-3zhi

Jira ticket: AR-2431

github-actions[bot] avatar Jul 25 '24 11:07 github-actions[bot]

Use Docker to Build

Please provide full command.

igorpecovnik avatar Jul 25 '24 12:07 igorpecovnik

Just ./compile.sh docker-shell The problem is not the compilation instructions, but the docker run instructions in build/lib/functions/cli/cli-docker.sh are too long. The same problem exists in build/lib/functions/host/docker.sh.

liu2-3zhi avatar Jul 25 '24 13:07 liu2-3zhi

What needs to be done now is to shorten the length of the docker run command. Perhaps you can consider using docker compose.

liu2-3zhi avatar Jul 25 '24 13:07 liu2-3zhi

Docker is used automatically (if installed on host) and docker-shell is, IIRC, deprecated.

igorpecovnik avatar Jul 25 '24 13:07 igorpecovnik

I also got the same error when using docker automatic mode. The instructions are as follows (please note that I added a new configuration file baicai-h6-pro, but the key to the problem is that the docker run command is too long)

./compile.sh docker BOARD=baicai-h6-pro BRANCH=current BUILD_DESKTOP=yes BUILD_MINIMAL=no DESKTOP_APPGROUPS_SELECTED='browsers chat desktop_tools editors email internet multimedia office programming remote_desktop' DESKTOP_ENVIRONMENT=xfce DESKTOP_ENVIRONMENT_CONFIG_NAME=config_base KERNEL_CONFIGURE=yes RELEASE=noble

liu2-3zhi avatar Jul 25 '24 13:07 liu2-3zhi

Try this way - (without docker command)

./compile.sh BOARD=baicai-h6-pro BRANCH=current BUILD_DESKTOP=yes BUILD_MINIMAL=no DESKTOP_APPGROUPS_SELECTED='browsers chat desktop_tools editors email internet multimedia office programming remote_desktop' DESKTOP_ENVIRONMENT=xfce DESKTOP_ENVIRONMENT_CONFIG_NAME=config_base KERNEL_CONFIGURE=yes RELEASE=noble

igorpecovnik avatar Jul 25 '24 13:07 igorpecovnik

I'm very sorry, I'm using Ubuntu 24.04 which is not supported, I can only compile using docker.

liu2-3zhi avatar Jul 25 '24 13:07 liu2-3zhi

I'm very sorry, I'm using Ubuntu 24.04 which is not supported, I can only compile using docker.

I use openSUSE and run in QEMU\KVM+ Virtual Machine Manager

The-going avatar Jul 25 '24 13:07 The-going

I tested it and found that it can be compiled successfully without installing Docker in Ubuntu 22.04. But it is undeniable that there is still a problem with the Docker run command.

liu2-3zhi avatar Jul 25 '24 14:07 liu2-3zhi

still a problem with the Docker run command.

No, there are no problems with Docker. Just documentation is outdated. If you have Docker installed, it will use it. If you don't have it, it will tell you that (warning), but also try to build. We are already testing 24.04 and most of things can be compiled.

igorpecovnik avatar Jul 25 '24 14:07 igorpecovnik

If I compile with docker, I just get /usr/bin/docker: Argument list too long. what currently need is to split the long docker run command to solve the problem.

liu2-3zhi avatar Jul 25 '24 14:07 liu2-3zhi

Does this works for you:

./compile.sh build BOARD=orangepioneplus BRANCH=current BUILD_DESKTOP=yes BUILD_MINIMAL=no DESKTOP_APPGROUPS_SELECTED='browsers chat desktop_tools editors email internet multimedia office programming remote_desktop' DESKTOP_ENVIRONMENT=xfce DESKTOP_ENVIRONMENT_CONFIG_NAME=config_base KERNEL_CONFIGURE=yes RELEASE=noble

igorpecovnik avatar Jul 25 '24 14:07 igorpecovnik

It seems that the instructions do not add docker. As long as docker is not used, the compilation can be completed on Ubuntu 22.04.

liu2-3zhi avatar Jul 25 '24 14:07 liu2-3zhi

As long as docker is not used

Can you provide logs for this build?

igorpecovnik avatar Jul 25 '24 14:07 igorpecovnik

I can't test it yet, but I seem to have found a log file that compiled without docker on ubuntu 22.04. I just want to report that the docker instructions are too long, not that I can't compile at all. log-build-28f0dd7f-cae9-49fb-a243-d768499914b2.log

Log when using docker compilation

https://paste.armbian.com/pikunapaka

liu2-3zhi avatar Jul 25 '24 14:07 liu2-3zhi

I can't reproduce or see the problem. It works here, our CI works fine. Lets keep this open if someone else come up with some ideas.

igorpecovnik avatar Jul 25 '24 14:07 igorpecovnik

i can't reproduce your problem, on my host work correctly

SuperKali avatar Sep 06 '24 17:09 SuperKali