【发布时间】:2017-01-27 13:44:27
【问题描述】:
我创建了我的第一个 Dockerfile,但是当我运行命令时
sudo docker ps
容器没有在后台运行,这是我的 dockerfile:
# Set the base image to Ubuntu
FROM debian:jessie
# File Author / Maintainer
MAINTAINER <Qop>
# Update the repository sources list
RUN apt-get update
################## BEGIN INSTALLATION ######################
RUN apt-get update && apt-get upgrade -y
RUN apt-get install -y \
vim \
apache2
##################### INSTALLATION END #####################
# Expose the default port
EXPOSE 81
# Default port to execute the entrypoint (MongoDB)
CMD ["--port 81"]
# Set default container command
ENTRYPOINT /bin/bash
【问题讨论】:
标签: docker dockerfile docker-build