浏览代码

Document link aliases

Aanand Prasad 11 年之前
父节点
当前提交
be1ba818e4
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      docs/yml.md

+ 4 - 1
docs/yml.md

@@ -24,9 +24,12 @@ build: /path/to/build/dir
 -- Override the default command.
 command: bundle exec thin -p 3000
 
--- Link to containers in another service
+-- Link to containers in another service. Optionally specify an alternate name
+-- for the link, which will determine how environment variables are prefixed,
+-- e.g. "db" -> DB_1_PORT, "db:database" -> DATABASE_1_PORT
 links:
  - db
+ - db:database
  - redis
 
 -- Expose ports. Either specify both ports (HOST:CONTAINER), or just the