Created
August 2, 2015 14:00
-
-
Save usmanismail/8a39047ca2d2ebe00800 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Goauth: | |
image: go-auth | |
ports: | |
- "9000:9000" | |
stdin_open: true | |
links: | |
- Database:db | |
command: | |
- "--db-host" | |
- "db" | |
tty: true | |
Database: | |
image: mysql | |
environment: | |
MYSQL_ROOT_PASSWORD: rootpass | |
MYSQL_DATABASE: messenger | |
MYSQL_USER: messenger | |
MYSQL_PASSWORD: messenger | |
expose: | |
- "3306" | |
stdin_open: true | |
tty: true | |
Goauth1: | |
image: go-auth | |
ports: | |
- "9000:9000" | |
stdin_open: true | |
links: | |
- Database:db | |
command: | |
- "--db-host" | |
- "db" | |
tty: true | |
Database1: | |
image: mysql | |
environment: | |
MYSQL_ROOT_PASSWORD: rootpass | |
MYSQL_DATABASE: messenger | |
MYSQL_USER: messenger | |
MYSQL_PASSWORD: messenger | |
expose: | |
- "3306" | |
stdin_open: true | |
tty: true | |
and Goauth1 should redirect port 9001 to 9000, if not it will be conflict with Goauth
You are both right. It even states this in the related blog post.
The only change is that in Goauth1 we need to change the ports entry from 9000:9000 to 9001:9000.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I haven't used compose much, but shouldn't Goauth1 link to Database1:db? Also, I'm reading your CI/CD eBook. Great stuff.