diff options
author | 2019-03-22 10:00:43 +0200 | |
---|---|---|
committer | 2019-04-03 09:27:58 +0200 | |
commit | 3be94e442b03dbf4710eafef1a5079a120ca384d (patch) | |
tree | add260de00bf93f6e63e4412f16d8d11f6eac5d9 /ansible/test/images/docker/centos7/Dockerfile | |
parent | 53036e8f41f50cb7ebb2346d02442d80bc16ece0 (diff) |
Building and Dockerfile for centos7
Add initial Dockerfile for centos7 for molecule testing.
Issue-ID: OOM-1750
Change-Id: Ie4da3d80c713d1da56465c598774b370b4c01b36
Signed-off-by: Samuli Silvius <s.silvius@partner.samsung.com>
Diffstat (limited to 'ansible/test/images/docker/centos7/Dockerfile')
-rw-r--r-- | ansible/test/images/docker/centos7/Dockerfile | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/ansible/test/images/docker/centos7/Dockerfile b/ansible/test/images/docker/centos7/Dockerfile new file mode 100644 index 00000000..8c024ab9 --- /dev/null +++ b/ansible/test/images/docker/centos7/Dockerfile @@ -0,0 +1,29 @@ +# https://github.com/chrismeyersfsu/provision_docker/tree/master/files +FROM centos:centos7 +ENV container docker + +RUN yum -y update; yum clean all + +RUN systemctl mask dev-mqueue.mount dev-hugepages.mount \ + systemd-remount-fs.service sys-kernel-config.mount \ + sys-kernel-debug.mount sys-fs-fuse-connections.mount \ + display-manager.service graphical.target systemd-logind.service + +RUN yum -y install openssh-server sudo openssh-clients \ + epel-release python-docker-py iproute +RUN sed -i 's/#PermitRootLogin no/PermitRootLogin yes/' /etc/ssh/sshd_config +RUN ssh-keygen -q -f /etc/ssh/ssh_host_rsa_key -N '' -t rsa && \ + ssh-keygen -q -f /etc/ssh/ssh_host_ecdsa_key -N '' -t ecdsa && \ + ssh-keygen -q -f /etc/ssh/ssh_host_ed25519_key -N '' -t ed25519 +RUN echo 'root:docker.io' | chpasswd +RUN systemctl enable sshd.service + +# firewalld needs this .. and I needs my firewalld +ADD dbus.service /etc/systemd/system/dbus.service +RUN systemctl enable dbus.service + +VOLUME ["/run"] + +EXPOSE 22 + +CMD ["/usr/sbin/init"] |