9e0bd9b7a1f33a06725baef3f65f06eb506fc719
docker/docker compose\343\201\256\343\203\255\343\202\260\343\202\222journald\343\201\253\343\201\246\347\256\241\347\220\206\343\201\231\343\202\213.md
... | ... | @@ -0,0 +1,20 @@ |
1 | +## 例 |
|
2 | + |
|
3 | +[https://qiita.com/gzock/items/e907cfce77e55ad6adeb](https://qiita.com/gzock/items/e907cfce77e55ad6adeb)からの引用。 |
|
4 | + |
|
5 | +``` |
|
6 | +version: "3" |
|
7 | +services: |
|
8 | + test-container-service: |
|
9 | + image: centos:7 |
|
10 | + container_name: test-container |
|
11 | + logging: |
|
12 | + driver: journald |
|
13 | + options: |
|
14 | + tag: "{{.Name}}" |
|
15 | +``` |
|
16 | + |
|
17 | + |
|
18 | +## 参考 |
|
19 | +- [https://docs.docker.jp/v19.03/config/container/logging/configure.html#supported-logging-drivers](https://docs.docker.jp/v19.03/config/container/logging/configure.html#supported-logging-drivers) |
|
20 | +- [dockerのlog-driverでjournaldを使ったときにコンテナ名を表示させる: https://qiita.com/gzock/items/e907cfce77e55ad6adeb](https://qiita.com/gzock/items/e907cfce77e55ad6adeb) |
|
... | ... | \ No newline at end of file |