int128 / slack-docker

Slack/Mattermost Integration for notifying Docker events, written in Go
Apache License 2.0
113 stars 30 forks source link

ARM64 image #16

Closed t-abraham closed 3 years ago

t-abraham commented 4 years ago

Hi, I know the repo is old and not maintained anymore, but we are using it in our docker swarm to get event notifications in slack. The current swarm is in AMD64 and your image works flawlessly, but I am adding another swarm hosted in ARM64 and there the image is not working. I was wondering if you could please provide me with some support to run your image on ARM64 architecture too.

Thank you

int128 commented 4 years ago

I added linux_arm64 release since v2.0.2.

I don't know how to set up the automated build for ARM64 on Docker Hub. Please tell me if you know.

t-abraham commented 4 years ago

HI,

I have not tested the CI7CD or auto build for the multi arch yet for my apps yet but i got a decent idea on how it works. Its a special feature from docker.config which needs to be activated from the uploading device. It the manifest option.

try looking into these 3 forums.

https://artisticcheese.wordpress.com/2018/06/09/using-vsts-for-complete-ci-cd-pipeline-and-multi-arch-docker-images/

https://www.docker.com/blog/multi-arch-images/

https://hub.docker.com/r/ckulka/multi-arch-example

t-abraham commented 4 years ago

Hi, I have a noob question.

How do I load the arm image in docker which you posted in the zip files in last release?

P.S. I also have a proposal. Do you think we can integrate apprise ( @https://github.com/caronc/apprise) to send the event notifications? Apprise supports Many platforms like slack telegram WhatsApp azure etc etc

int128 commented 4 years ago

slack-docker_linux_arm64.zip has an executable for Linux ARM64. Please let me know if you need other platforms. (I don't know much about arm build...)

Do you think we can integrate apprise ( @https://github.com/caronc/apprise) to send the event notifications?

Seems good. I will take a look.

t-abraham commented 4 years ago

Hi, thank for your answer and your will to look in apprise. Please do let me know if I can help you with python.

P.S I am not sure what you meant by the executable file. Is that a docker image? I will be using slack notifier in docker containers. Would you please give me a bit in details on how to use the arm image?

robgmills commented 3 years ago

Mind if I take a shot at creating a multi-arch Docker manifest with images and add an arm release along the way?

robgmills commented 3 years ago

There's some good prior art in ContainerSolutions/trow that I'll probably follow. Their Dockerfiles look to be much more involved than what I think would be required in this case thanks to your awesome CircleCI/goreleaser/goxzst/ghcp pipeline.

It doesn't look like you have CI/CD set up for releasing the container images to Docker Hub. Am I missing that somewhere? I just don't want to break existing automation if you have it.

I think my proposal will be to:

  1. Update the existing Dockerfile to source the binary from the GitHub releases rather than rebuild it in a multi-stage build.
  2. Parameterize the Dockerfile to accept different binaries or add separate Dockerfiles for each binary based on platform architecture
  3. Move all the Docker stuff to a subdirectory docker/ to try to keep the root of the repository organized.
int128 commented 3 years ago

Sorry for the late response. I migrated the CI/CD pipeline to GitHub Actions and the image to GHCR. Now the multi platform image is available on https://github.com/users/int128/packages/container/package/slack-docker.

robgmills commented 3 years ago

Works for me!

I added #36 to also support ARM v7 because I've got a mix of hardware including some legacy nodes that I'd like to run this on.

int128 commented 3 years ago

@robgmills Thank you for your contribution. I released v2.2.0 and the multi-platform images are available on https://github.com/users/int128/packages/container/package/slack-docker.

image

Could you check it?

robgmills commented 3 years ago

@int128 - I can confirm that the image ghcr.io/int128/slack-docker runs on ARM64 and ARMv7 architectures. Thanks for the updates!