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

Docker Container on Rock64 64Bit ARM. Doesn't run unless built from source. #7541

Closed
BunkerMelon opened this issue Jul 15, 2020 · 13 comments · Fixed by #10021
Closed

Docker Container on Rock64 64Bit ARM. Doesn't run unless built from source. #7541

BunkerMelon opened this issue Jul 15, 2020 · 13 comments · Fixed by #10021
Labels
exp/intermediate Prior experience is likely helpful help wanted Seeking public contribution on this issue kind/bug A bug in existing code (including security flaws) P3 Low: Not priority right now status/ready Ready to be worked topic/ARM Issues related to running on ARM topic/containers + vms

Comments

@BunkerMelon
Copy link

Version Info
Golang version: 1.14
IPFS Version: Latest, Docker container
Architecture: aarch64/Cortex-A53
Operating System: Ubuntu 20.05.4

Description
Wanted to test running IPFS docker image on my Pine64 SBC. Went over to dockerhub and found the go-ipfs image
Went ahead and pulled this image; "docker pull ipfs/go-ipfs".

This downloaded and extracted fine, but when doing a test run with "docker run -d --name ipfs_host -v $ipfs_staging:/export -v $ipfs_data:/data/ipfs -p 4001:4001 -p 127.0.0.1:8080:8080 -p 127.0.0.1:5001:5001 ipfs/go-ipfs:latest" I get the container hash that the container started, but when checking logs "docker logs -f ipfs_host" I recieve exec user process caused "exec format error" similair to the problem encountered here #7422

When running docker ps -a I can see the container was exited as soon as it was started.

I was able to solve this problem by cloning the repo and building the image myself (no changes to the Dockerfile) and re-running the docker run command listed above. I have a spare Rock64 where I can reproduce this for testing.

@BunkerMelon BunkerMelon added kind/bug A bug in existing code (including security flaws) need/triage Needs initial labeling and prioritization labels Jul 15, 2020
@welcome
Copy link

welcome bot commented Jul 15, 2020

Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review.
In the meantime, please double-check that you have provided all the necessary information to make this process easy! Any information that can help save additional round trips is useful! We currently aim to give initial feedback within two business days. If this does not happen, feel free to leave a comment.
Please keep an eye on how this issue will be labeled, as labels give an overview of priorities, assignments and additional actions requested by the maintainers:

  • "Priority" labels will show how urgent this is for the team.
  • "Status" labels will show if this is ready to be worked on, blocked, or in progress.
  • "Need" labels will indicate if additional input or analysis is required.

Finally, remember to use https://discuss.ipfs.io if you just need general support.

@Stebalien Stebalien added exp/intermediate Prior experience is likely helpful P3 Low: Not priority right now topic/containers + vms help wanted Seeking public contribution on this issue and removed need/triage Needs initial labeling and prioritization labels Jul 20, 2020
@Stebalien
Copy link
Member

This probably has something to do with how we build and deploy to dockerhub (https://github.com/ipfs/go-ipfs/blob/480defab689610550ee3d346e31441a2bb881fcb/.circleci/config.yml#L308-L340). We probably need some extra logic to get this to work cross-architecture.

Unfortunately, this is not something the go-ipfs team is likely to have time to tackle in the near future. However, if you have some spare time and want to try to get cross building working on CircleCI, it looks like https://www.docker.com/blog/multi-arch-build-what-about-circleci/ is a good place to start.

@BunkerMelon
Copy link
Author

Ah okay, that makes sense. Thank you for the confrimation. If I do get some spare time, I will look deeper into the cross building issue.

Totally understandable that this isn't a top priority, just thought I would bring it to the teams attention if they weren't aware. If I come up with any solutions for this, I will surely return back with a solution.

@Stebalien
Copy link
Member

Yeah, thanks for bringing this up.

@mahoekst
Copy link

mahoekst commented Oct 5, 2020

Also an issue if you want to run ipfs-go in docker on a Raspberry currently. The build from the docker file works flawlessly though. But it would be nice to be able to refer to a single image from the docker-compose file to support amd64 and arm64

@lidel lidel added the topic/ARM Issues related to running on ARM label Oct 23, 2020
@sevenrats
Copy link

sevenrats commented Jun 13, 2021

the provided docker compose still fails on raspberry pi 4 with pulled images, but still works on images built from source.
linuxserver has been maintaining a multi-platform-aware ipfs image for awhile that, at a glance, appears to be go-ipfs in alpine.
https://github.com/linuxserver/docker-ipfs
Why not do what they do?

@christroutner
Copy link

Could someone build a Raspberry Pi version of go-ipfs, upload it to Docker Hub, and post a link to this thread?

@christroutner
Copy link

It looks like #4931 has some links to Docker images on Docker Hub.

@christroutner
Copy link

I was able to get this Docker container to run go-ipfs v11 on a Raspberry Pi 4:

https://hub.docker.com/layers/go-ipfs/odanado/go-ipfs/v0.11.0/images/sha256-3688a5a1b90cc343e1cfcc2fcf1bd199b93035a9974331e6de55490896f38993?context=explore

@mahoekst
Copy link

I build my own as well to run on my rpi4, would be nice if they would build an ARM build. I wish I knew how to change their builds to fix it, but no clue unfortunately,

@guseggert
Copy link
Contributor

We did add ARMv7 and ARM64 builds recently, but they are not running for tagged releases, which is a bug, so I just opened #8829. But you can see them on the master branch builds here: https://hub.docker.com/r/ipfs/go-ipfs/tags .

@guseggert
Copy link
Contributor

Sorry not a bug, it just hasn't been included in a release yet. It should be in v0.13. Once v0.13.0-rc1 is released, we should auto-publish an ARM docker image...it'd be really helpful if you try those out on your devices and let us know if it works.

@lidel
Copy link
Member

lidel commented Jul 27, 2023

Fixed in #10021, will ship when final Kubo 0.22.0 is released.

@lidel lidel closed this as completed Jul 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
exp/intermediate Prior experience is likely helpful help wanted Seeking public contribution on this issue kind/bug A bug in existing code (including security flaws) P3 Low: Not priority right now status/ready Ready to be worked topic/ARM Issues related to running on ARM topic/containers + vms
Projects
None yet
8 participants