Skip to content

Instantly share code, notes, and snippets.

@mss
Created October 7, 2013 18:16
Show Gist options
  • Save mss/6872494 to your computer and use it in GitHub Desktop.
Save mss/6872494 to your computer and use it in GitHub Desktop.
A docker host serving Rails and PHP containers.
blockdiag {
orientation = portrait;
default_shape = roundedbox;
default_group_color = "#808080";
user [shape = actor]
inet [shape = cloud];
user -> inet
inet -> nginx [label = "HTTP(S)"];
inet -> docker-registry [label = "(deploy)", style = "dotted"]
group host {
label = "*.example.com";
nginx [label = "nginx (Reverse Proxy)"]
nginx -> rails-nginx, php-apache [label = "HTTP"];
docker-registry -> docker
group docker-registry {
color = "#004040";
docker-registry;
}
group rails-container {
color = "#00C0C0";
rails-nginx [label = "nginx"];
rails-nginx -> rails-puma, rails-static;
rails-nginx -> rails-puma [label = "HTTP"];
rails-puma [label = "puma"];
rails-puma -> rails;
rails-static [label = "static files"];
rails [label = "Rails"];
}
php-fpm -> php;
group php-container {
color = "#00C0C0";
php-apache [label = "Apache"];
php-apache -> php-fpm, php-static;
php-apache -> php-fpm [label = "FastCGI"];
php-fpm [label = "PHP FPM"];
php-fpm -> php;
php-static [label = "static files"];
php [label = "PHP"];
}
rails, php -> mysql, postfix;
group mysql-container {
color = "#004040";
mysql [shape = "flowchart.database", label = "MySQL"];
}
group postfix-container {
color = "#004040";
postfix [shape = "mail", label = "Postfix"];
}
}
}
@mss
Copy link
Author

mss commented Oct 7, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment