Skip to content
This repository has been archived by the owner on Mar 7, 2020. It is now read-only.

Revisit how versions and tags work #20

Open
csmith opened this issue Nov 17, 2019 · 6 comments
Open

Revisit how versions and tags work #20

csmith opened this issue Nov 17, 2019 · 6 comments

Comments

@csmith
Copy link
Contributor

csmith commented Nov 17, 2019

At the moment we have:

  • master branch in oragono/oragono
    • pulled by master branch of oragono/oragono-docker
    • pushed to the :dev tag on Docker Hub
  • stable branch in oragono/oragono
    • pulled by stable branch of oragono/oragono-docker
    • pushed to the :latest tag on Docker Hub

I think there's a cronjob somewhere or other that triggers the build-and-push for each branch once an hour, which ensures the latest changes from Ora are picked up.

The only difference between the two branches is a -b stable in the Dockerfile.

Ideally we want:

  • master branch to be representative of what you find in the :latest tag, as is the norm. (It's amazingly confusing every time you forget that oragono-docker has a weird mapping between branches and tags)
  • tags for each released version of Oragono (Version tags to test older version? #18)
  • a way of building docker images in direct response to pushes to the oragono/oragono repository, instead of a batch update every hour whether it's needed or not
@slingamn
Copy link
Member

This all sounds great.

Would you be able to work on this? If so, do you need more permissions?

@slingamn
Copy link
Member

I googled a bit and found this workflow:

https://medium.com/better-programming/build-your-docker-images-automatically-when-you-push-on-github-18e80ece76af

it seems to involve moving Dockerfile and docker-compose.yml back into https://github.com/oragono/oragono proper, but maybe that's a feature, not a bug?

@csmith
Copy link
Contributor Author

csmith commented Nov 22, 2019

Sorry, missed the notification on this. Happy to run with it, yes.

Moving the Dockerfile and its associated bits and bobs into the main repo would be the path of least resistance, yeah. It would then just be a case of reconfiguring Dockerhub. The downside is the main repo getting being a bit cluttered (especially if down the line Docker isn't the only thing that needs its own special bits of glue - e.g. if someone wants to build debs or rpms or whatever).

If we stuck with separate repos I think you can probably still do it nicely with GitHub actions which I believe are now public (and are free for public repos).

Any thoughts on which way you want to lean?

@DanielOaks
Copy link
Member

when I created the separate -docker repo my main concern was just with cluttering, yeah. but honestly since we've ended up keeping the docker install the same as stock anyway apart from a couple tiny changes, moving all that back into the mainline repo sounds great to me if that's what you'd prefer.

will need to find a decent place to stash that run.sh file where it's out of the way, need to make sure people don't try to use it outside of automated docker stuff... I always planned on having some sorta distrib/<platform>/ folder for things like windows, systemd, etc weird specific files, maybe it'd be useful stashed away in a dir like that? (keeping dockerfile and -compose file in the base dir of course)

@csmith
Copy link
Contributor Author

csmith commented Nov 22, 2019

👍 Merging it back is definitely the easiest way. I'll prepare a PR at some point in the near future.

We could probably put all the docker files under distrib/docker - it would just mean to build you had to do docker -f distrib/docker/Dockerfile build instead of relying on the default behaviour of looking in the CWD.

csmith added a commit to csmith/oragono that referenced this issue Nov 22, 2019
This will allow easier building on docker hub and let us automatically
publish tags for each release.

Fixes oragono/oragono-docker#20
@slingamn slingamn reopened this Dec 3, 2019
@slingamn
Copy link
Member

slingamn commented Dec 3, 2019

Reopening this issue to cover the remaining action items:

  • Building the Dockerhub images from the oragono/oragono repository proper
  • Marking this repository as "archived"

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

No branches or pull requests

3 participants