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

added a git workflow for docker multiarch publish #53

Closed

Conversation

krasi-georgiev
Copy link

@krasi-georgiev krasi-georgiev commented Jul 24, 2020

closes: #43

Only the alpine image is multiarch as the official java doesn't support multiarch for debian.

It will auto-publish for all branches and it is triggered by any push. I can also set it to be triggered by only changes to the dockerfiles, but that is error prone if you decide to refactor the folder structure at some point.

You can see an example of a successful push here
https://github.com/arribada/traccar-docker/actions/runs/181356434
https://hub.docker.com/repository/docker/arribada/traccar/tags?page=1

Signed-off-by: Krasi Georgiev 8903888+krasi-georgiev@users.noreply.github.com

Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
@krasi-georgiev
Copy link
Author

ping @magna-z

@magna-z
Copy link
Member

magna-z commented Aug 3, 2020

Why do you edit README.md?
Why do you use 4 spaces in YAML?

Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
@krasi-georgiev
Copy link
Author

krasi-georgiev commented Aug 4, 2020

Why do you edit README.md?

because it is much easier to just mention that the images are constructed from the branch name instead of listing each one. less error prone. This way don't have to edit the readme every time you add a new docker image

Why do you use 4 spaces in YAML?

not sure what happened, I fixed it.

@krasi-georgiev
Copy link
Author

ping @magna-z

@toblie
Copy link

toblie commented Aug 21, 2020

hi, I tried to deploy traccar/traccar:latest and also traccar/traccar:4.10-alpine to my pine64 running armbian buster.
But badly both versions wasn't running and the log shows this error:

standard_init_linux.go:211: exec user process caused "exec format error"

Can anyone help me to get it working? I think it also caused of arm compatibility? Is there anything to do to get your multiarch version running?

Thanks so much!
Tobi

@krasi-georgiev
Copy link
Author

ping @magna-z

@magna-z
Copy link
Member

magna-z commented Sep 21, 2020

Files changed=598 - what is it???
This is small dedicated repository for build app in docker and nothing more!

…h-actions

Signed-off-by: Krasi Georgiev <8903888+krasi-georgiev@users.noreply.github.com>
@krasi-georgiev
Copy link
Author

hhm , not sure what happened, that was a mistake, it is fixed now.

@krasi-georgiev
Copy link
Author

ping @magna-z

@krasi-georgiev
Copy link
Author

is the team interested in this contribution or shall I close it?

@tananaev
Copy link
Member

tananaev commented Nov 2, 2020

I'll defer to @magna-z to decide.

@magna-z
Copy link
Member

magna-z commented Nov 2, 2020

README.md is broken.
This is statically file with information about project. Why make a template out of it?

- name: Print Branch name
run: 'echo running on branch ${GITHUB_REF##*/}'
- name: Build and publish image
uses: ilteoood/docker_buildx@master
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not docker/build-push-action?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes I just found out about it as well. Will refactor.

@krasi-georgiev
Copy link
Author

This is statically file with information about project. Why make a template out of it?

I can leave as is, just thought that this way will reduce the manual work a bit. Can revert it if you prefer to keep these manual entries. Let me know

@tedenda
Copy link

tedenda commented Dec 20, 2020

I am also interesting to run Traccar in docker on RPi 4 8GB.
Any estimate on when this PR can be done and merged?

@krasi-georgiev
Copy link
Author

This needs to be updated with the official multiarch docker build docker/build-push-action , but haven't had the time to refactor it. @tedenda feel free to take over this PR to refactor.

@tedenda
Copy link

tedenda commented Dec 21, 2020

I don't have the skills to do that I'm afraid. I'm a docker user that still only use prebuilt containers. Would like to learn to build custom made containers some day.

Hopefully someone else can help this PR over the finish line. Thanks for your efforts with this PR!

@tedenda
Copy link

tedenda commented Dec 21, 2020

As I said, this is not in my skillset, but maybe it is something like this?

    runs-on: ubuntu-latest
    name: Push alpine image
    steps:
      - 
        name: Checkout master
        uses: actions/checkout@master
      - 
        name: Print Branch name
        run: 'echo running on branch ${GITHUB_REF##*/}'
      - 
        name: Set up Docker Buildx
        uses: docker/setup-buildx-action@v1
      -
        name: Login to DockerHub
        uses: docker/login-action@v1
        with:
          username: ${{ secrets.DOCKER_USERNAME }}
          password: ${{ secrets.DOCKER_PASSWORD }}
      -
        name: Build and push
        uses: docker/build-push-action@v2
        with:
          context: .
          file: ./alpine/Dockerfile
          push: true
          tags: |
            '${GITHUB_REF##*/}-alpine'
            traccar/traccar:alpine

@tedenda
Copy link

tedenda commented Dec 21, 2020

This is statically file with information about project. Why make a template out of it?

I can leave as is, just thought that this way will reduce the manual work a bit. Can revert it if you prefer to keep these manual entries. Let me know

@magna-z Any answer to this question?

@magna-z
Copy link
Member

magna-z commented Jan 7, 2021

Multi-platform docker images released for current version 4.11. Details in README.md

@magna-z magna-z closed this Jan 7, 2021
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 this pull request may close these issues.

Raspberry pi ARM support
5 participants