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

Add networking support #170

Merged
merged 13 commits into from
Nov 9, 2020
Merged

Add networking support #170

merged 13 commits into from
Nov 9, 2020

Conversation

mattstauffer
Copy link
Member

@mattstauffer mattstauffer commented Nov 6, 2020

Networking Todo:

  • Put all containers into a takeout network
  • Test (somehow?) that this network means other Docker containers can be accessed by their full name (e.g. TO--mailhog--v1.0.1) in the target Docker-based Laravel apps
  • Figure out how to make it so my MySQL Docker container is accessible as mysql--alias
  • How do we make it so people with only one container get mysql easily, but people with multiple MySQL containers also have something usable
  • Tag all new containers with serviceVersion (e.g. mysql80)
  • Tag the first container with the short version (e.g. mysql)
  • Clean up the version number?
  • Extract Docker Networking methods to a separate class
  • Test the things with @test on them

Brainstorm on the naming situation:

  • By default, each service aliases itself to just its service name (e.g. mysql)

Every container gets tagged with mysql80:

@josecanhelp gave his blessing to Option 1 🙌

  • Option 1:

    • All MySQL instances (e.g.) are tagged with their name and version (e.g. mysql80) and the first instance of that type that I spin up also gets the short version (mysql), with the intention of later making it so we can allow them to repoint the shortcut
  • Option 2:

    • If I spin up a second MySQL instance, it spins down my first, and then names them all as mysql57, mysql80, etc. and points the short name (mysql) to the latest of those I have open

Every container doesn't necessarily get tagged with the version:

  • Option 3:

    • If I spin up a second MySQL instance, it spins down my first, and then names them all as mysql57, mysql80, etc.
  • Option 4: (not prefered)

    • We require a nickname for every new container spun up, and that's used for its alias
  • Option 5: (not prefered)

    • Number them. mysql1, mysql2 ,
      etc

@mattstauffer mattstauffer marked this pull request as ready for review November 7, 2020 00:00
@mattstauffer
Copy link
Member Author

Not sure why WIndows is erroring but it has nothing to do with this code.

@mattstauffer
Copy link
Member Author

Crap. One fix needed:

image

This thing is way too long.

@mattstauffer mattstauffer merged commit d9052ea into main Nov 9, 2020
@mattstauffer mattstauffer deleted the mes/networking branch November 9, 2020 15:53
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.

1 participant