donnemartin / saws

A supercharged AWS command line interface (CLI).
Other
5.24k stars 281 forks source link

Publish docker image on DockerHub #51

Open frosforever opened 8 years ago

frosforever commented 8 years ago

Leverage DockerHub's Automated build to pick up changes and deploy public saws image to dockerhub. My understanding is this should be done under @donnemartin's account as he is the owner of saws unless someone else has a better idea on this.

This would require:

donnemartin commented 8 years ago

@frosforever thanks for looking further into this and for the followup. I'll see if I can add this to DockerHub in the next week or so.

frosforever commented 8 years ago

@donnemartin sure thing. If it's any help, I can attempt to run through the steps and publish on my account working out the kinks and then hand over the steps I took. I don't know if there's a better way. It would be cool if one could publish on behalf of a user/repo via docker hub, but I don't know if that's possible.

Also, I realized the current Dockerfile installs via pip and not from the current state of the repo. This might cause a consistency issue with the automated build.

donnemartin commented 8 years ago

If it's any help, I can attempt to run through the steps and publish on my account working out the kinks and then hand over the steps I took

@frosforever I think this would be a big help, I've been pretty tied up lately.

Also, I realized the current Dockerfile installs via pip and not from the current state of the repo. This might cause a consistency issue with the automated build.

Hmm interesting catch.

Thanks for your previous contribution, I released it to GitHub and PyPI today and of course credited you :)

https://github.com/donnemartin/saws/releases/tag/0.3.2 https://pypi.python.org/pypi/saws

frosforever commented 8 years ago

@donnemartin it ebbs and flows. I'm currently a bit swamped as well but I'll try and get on this sometime.

donnemartin commented 8 years ago

@frosforever no rush!

sysadmiral commented 8 years ago

This would be super useful.

Not sure if this helps or not but codeclimate do something similar with a wrapper script for the docker process (although that's a ruby app):

https://github.com/codeclimate/codeclimate

sysadmiral commented 8 years ago

FWIW I have published my image to the docker hub: https://hub.docker.com/r/sysadmiral/saws/

A few things to note:

Please let me know what you think! If you think the Dockerfile is suitable I can create a PR to update the official one in this repo so that the one on docker hub can be from the official SAWS source?

donnemartin commented 8 years ago

@sysadmiral thanks for the help on docker support!

Please let me know what you think! If you think the Dockerfile is suitable I can create a PR to update the official one in this repo so that the one on docker hub can be from the official SAWS source?

I'm not really a docker user myself so I'm not sure I'm the best person to comment.

Perhaps our other docker users (@frosforever @cliveza @stilvoid) might share their thoughts :)

frosforever commented 8 years ago

Wow, I completely forgot about this!

@sysadmiral Thanks for bringing this up. A few things as I see it:

I've submitted #84 that uses the official python alpine image and builds from sources instead of installing from pip should it be decided that that's the way to go. I've also set up an automated build https://hub.docker.com/r/frosforever/saws/

@sysadmiral What do you think? It seems that your image is a bit smaller (104.8MB vs 97.91MB) but that might just be splitting hairs.

sysadmiral commented 8 years ago

Glad I got this moving! :smile:

@frosforever just to expand on some of my decisions/your points:

I will check out PR #84 later this evening (GMT).

donnemartin commented 8 years ago

I couldn't comment on building saws from source instead of using the pip package...

You can install the latest from GitHub source which can contain changes not yet pushed to PyPI:

$ pip install git+https://github.com/donnemartin/saws.git

I haven't refreshed the version on PyPI in awhile (5 months and 35 commits behind), although I plan to do so soon. Pushing to PyPI is more involved than pushing to master :)

I think installing from source is probably a better option if you always want the latest changes.