润泊坞窗图像的httpd支持SSL

时间:2019-02-01 12:22:39

标签: docker dockerfile

我试图使用SSL运行HTTP。和接收以下错误。 我是新来泊坞conatiner。只是想学习它。

网站(图像)我下面:

https://hub.docker.com/_/httpd

其他必需的文件和信息

#cat DockerFile2 
FROM httpd
RUN sed -i \
        -e 's/^#\(Include .*httpd-ssl.conf\)/\1/' \
        -e 's/^#\(LoadModule .*mod_ssl.so\)/\1/' \
        -e 's/^#\(LoadModule .*mod_socache_shmcb.so\)/\1/' \
        conf/httpd.conf



#docker build -f DockerFile2 -t apache-ssl .
Sending build context to Docker daemon 8.192 kB
Step 1/2 : FROM httpd
 ---> e40405f80704
Step 2/2 : RUN sed -i         -e 's/^#\(Include .*httpd-ssl.conf\)/\1/'         -e 's/^#\(LoadModule .*mod_ssl.so\)/\1/'         -e 's/^#\(LoadModule .*mod_socache_shmcb.so\)/\1/'         conf/httpd.conf
 ---> Running in 2f84a0a0dc32

 ---> 5e46a5041bc9
Removing intermediate container 2f84a0a0dc32
Successfully built 5e46a5041bc9

错误:

#docker run -p 443:443 -d apache-ssl
8b3d82f54837e55e7857ac3d80735c50a72e16af76c4ca29a80fd5b7d540ad61
/usr/bin/docker-current: Error response from daemon: driver failed programming external connectivity on endpoint optimistic_northcutt (11039d1ab62c53d49038db25c2982ce6fb475dca3549aa6c63b54d46dbbc5d34):  (iptables failed: iptables --wait -t nat -A DOCKER -p tcp -d 0/0 --dport 443 -j DNAT --to-destination 172.17.0.2:443 ! -i docker0: iptables: No chain/target/match by that name.
 (exit status 1)).

0 个答案:

没有答案