728x90
300x250
Centos6.10
FROM centos:centos6.10
#ENV SSH_PASSWORD=
# Install base tool
RUN yum -y install vim wget tar
RUN yum -y install \
scl-utils \
centos-release-scl-rh \\
vim \
wget \
tar \
curl \
gcc \
gcc-c++ \
openssl-devel \
bzip2-devel
# Install develop tool
RUN yum -y groupinstall development
# Install crontab service
RUN yum -y install vixie-cron crontabs
# Install MariaDB(Only Client)
RUN echo -e "[mariadb]" >> /etc/yum.repos.d/MariaDB.repo && \
echo -e "name = MariaDB" >> /etc/yum.repos.d/MariaDB.repo && \
echo -e "baseurl = http://yum.mariadb.org/5.5.67/centos6-amd64" >> /etc/yum.repos.d/MariaDB.repo && \
echo -e "gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB" >> /etc/yum.repos.d/MariaDB.repo && \
echo -e "gpgcheck=1" >> /etc/yum.repos.d/MariaDB.repo && \
yum -y install MariaDB-client
# Copy files for setting
ADD . /opt/
# Setting DateTime Zone
RUN cp -p /usr/share/zoneinfo/Asia/Seoul /etc/localtime
# Setup default path
WORKDIR /
# Private expose
#EXPOSE 80
#EXPOSE 22
# Volume for web server install
VOLUME ["/home/website","/home/config","/home/logs"]
# Start run shell
CMD ["bash"]
Centos6_php56
FROM centos:centos6
RUN yum repolist \
&& yum -y install vi vim \
&& yum -y install httpd \
&& yum -y install initscripts \
&& yum -y update
RUN rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
RUN yum clean all && \
yum -y install php56w php56w-common
RUN cp -p /usr/share/zoneinfo/Asia/Seoul /etc/localtime
EXPOSE 80
CMD /bin/bash
ENTRYPOINT /usr/sbin/httpd -D FOREGROUND
Centos 7
FROM centos:centos7
#ENV SSH_PASSWORD=
# Install base tool
RUN yum -y install vim wget tar
# Install develop tool
RUN yum -y groupinstall development
# Install SSH Service
RUN yum install -y openssh-server passwd
RUN sed -ri 's/#UsePAM no/UsePAM no/g' /etc/ssh/sshd_config && \
echo "${SSH_PASSWORD}" | passwd "root" --stdin
# Install crontab service
RUN yum -y install vixie-cron crontabs
# Copy files for setting
ADD . /opt/
# Setting DateTime Zone
RUN cp -p /usr/share/zoneinfo/Asia/Seoul /etc/localtime
# Setup default path
WORKDIR /
# Private expose
EXPOSE 80
# Volume for web server install
#VOLUME ["/home/website","/home/config","/home/logs"]
# Start run shell
CMD ["bash"]
Ubuntu_php5
FROM ubuntu:12.04
#VOLUME ["/var/www"]
RUN apt-get update && \
apt-get install -y \
apache2 \
php5 \
php5-cli \
libapache2-mod-php5 \
php5-gd \
php5-ldap \
php5-mysql \
php5-pgsql
#COPY apache_default /etc/apache2/sites-available/default
#COPY run /usr/local/bin/run
#RUN chmod +x /usr/local/bin/run
#RUN a2enmod rewrite
EXPOSE 80
CMD /bin/bash
728x90
300x250
'IT > Docker' 카테고리의 다른 글
[Docker] Docker-compose 실행시 build 오류 (2) | 2021.06.09 |
---|---|
[Docker] 도커 이용 mariadb 세팅 관련 메모 (0) | 2021.06.09 |
[Docker] Docker-Compose : LINUX + TOMCAT + JSP + MYSQL 세팅하기 (2) | 2021.04.27 |
[Docker] Docker 실행 에러 ERROR: ZONE_CONFLICT: 'docker0' already bound to a zone (0) | 2021.04.14 |
[Docker] Linux + Docker + Django + PostgreSQL 세팅하기 (0) | 2021.04.08 |