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 Image for ARM #12

Closed
fwidder opened this issue Jan 12, 2021 · 13 comments
Closed

Docker Image for ARM #12

fwidder opened this issue Jan 12, 2021 · 13 comments

Comments

@fwidder
Copy link

fwidder commented Jan 12, 2021

Please add a Docker Image for ARM7-Platform.

@alexta69
Copy link
Owner

Hi Florian,
Thanks for the contribution!
At the moment, Docker Hub automated builds are enabled for this project, so every push triggers a build there, and an image is created and retained for distribution by them. I think this is a perfect arrangement and it obviates the need for a CI pipeline here for now. Of course by default only x86_64 images are created. I'd prefer to merge a solution that leaves the build on Docker Hub, but adds images for other platforms, something along the lines of this:
https://github.com/ckulka/docker-multi-arch-example
If you want to push something like that, it'll be more than welcome.
Thanks again!
--Alex

@fwidder
Copy link
Author

fwidder commented Jan 12, 2021

Hey!

Sounds good! I'll take a look at it this weekend and revise the pull request!

Many greetings
Florian

@LeLunZ
Copy link

LeLunZ commented Jan 17, 2021

Would be really nice to have arm support!

@fwidder
Copy link
Author

fwidder commented Jan 22, 2021

Hey!

Took a little bit longer than planned ... but now it Should work! I Updated the Pull Request (#13 )

Many greetings
Florian

@alexta69
Copy link
Owner

Hey Florian!
That's a whole lot of code right there! Did you take it from somewhere or did you author it for this specific project?
Wrote a couple comments in the PR.
Thanks
Alex

@fwidder
Copy link
Author

fwidder commented Jan 24, 2021

Hey!

Yeah it's because of the bug mentioned here: https://github.com/ckulka/docker-multi-arch-example#known-limitations

It took the Solution from here: https://github.com/rmoriz/multiarch-test

I also mentioned it in my last Commit-Message.

I will have a look at your Comments on the Code next week and adapt the Code!

Many greetings
Florian

@xescure
Copy link

xescure commented Mar 6, 2021

Hey!

I know you've specifically stated that you don't want a CI pipeline, but they are just so practical and easy to setup. As far as I know GitHub actions are free for public repos, is there any other reason you would want to leave all the compiling to Docker Hub?

Just out of curiosity I've set it up in a few minutes with this official multiarch example and it works flawlessly.

Greetings,
Joseph

@alexta69
Copy link
Owner

alexta69 commented Mar 7, 2021

Hi @xescure
It does look very simple! Maybe it's a good idea. So if this is deployed, I'd want to disable the automatic building in Docker Hub, correct?
Do you know if there's any way to sync the README to Docker Hub automatically like it does now, if the automatic builds there are disabled?

Thanks!
Alex

@xescure
Copy link

xescure commented Mar 9, 2021

Hey,

I did not think of the README issue and I don't think there's a proper way of doing it, but I found this repo from linuxserver.io that solves the problem.

I came up with this based on the container, but bash -c 'node sync' is not passed properly and I can't figure out why. I'll probably have time later this week to figure it out, but I'd appreciate if someone helped me out before that.

jobs:
  dockerhub-sync-readme:
    runs-on: ubuntu-latest
    steps:
      - name: sync readme
        uses: docker://lsiodev/readme-sync:latest
        env:
          DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
          DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_PASSWORD }}
          GIT_REPOSITORY: xescure/metube-multiarch
          DOCKER_REPOSITORY: xescure/metube-multiarch
          GIT_BRANCH: main
        with:
          args: bash -c 'node sync'

Greetings
J

@alexta69
Copy link
Owner

alexta69 commented Mar 9, 2021

Hey @xescure ,

Looks like a perfectly valid way to do it to me! :)

I tried to understand the problem and it looks to me this -- with: args: specifies the arguments to the entrypoint defined by the Dockerfile, but the Dockerfile for readme-sync doesn't have an entrypoint (as you can see here - https://github.com/linuxserver/docker-readme-sync/blob/master/Dockerfile). It seems that the entrypoint and its arguments have to be specified separately, if I'm reading the docs correctly, so it should be something like:

        with:
          entrypoint: /bin/bash
          args: -c 'node sync'

Would you mind testing it in your repo, since you already have everything set up for it? If it works, then we can merge it into metube.

Thanks again,
Alex

@xescure
Copy link

xescure commented Mar 10, 2021

Hey, @alexta69,

The solution was a combination of fixing the entrypoint and the workdir. I compiled everything so far into a PR. If you see no other issues, then it can be merged and tested.

Greetings
J

#23

@xescure
Copy link

xescure commented Mar 10, 2021

Hey @alexta69,

It seems to be working just fine. I've just tested it on my Raspberry Pi, but I have no way of checking the other archs. Did you notice any issues with the images or the build process?

@alexta69
Copy link
Owner

Hey @xescure ,
I checked the x64 image and it's working great. I've now pushed the change to the "latest" tag. If all works well (and there's no reason it shouldn't), we can consider it done. This is an amazing contribution, thanks so much!! I'm happy with the result.
@fwidder , I hope you also find it useful! Thanks a lot to you as well for your efforts!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants