fluentdが入りのcentos7のdockerコンテナを作る
仕事でCentOS7でfluentdを使う感じになった時の、開発環境を作ったメモ
DockerFile
FROM centos:7.2.1511
ENV APP_ROOT /app/
CMD ["rpm", "--import", "https://packages.treasuredata.com/GPG-KEY-td-agent"]
RUN echo $'[treasuredata] \n\
name=TreasureData \n\
baseurl=http://packages.treasuredata.com/3/redhat/\$releasever/\$basearch \n\
gpgcheck=1 \n\
gpgkey=https://packages.treasuredata.com/GPG-KEY-td-agent' >/etc/yum.repos.d/td.repo
RUN yum -y install td-agent
RUN systemctl enable td-agent
docker-compose.yml
version: '3'
services:
client:
build: ./client
tty: true
stdin_open: true
privileged: true
command: /sbin/init
とりあえず、これで、箱だけできる感じ。