I had a dockerfile which tried to install nginx like following:
Dockerfile
FROM ubuntu:latest
RUN apt-get update
RUN apt-get install -y expect
RUN apt-get -y install software-properties-common
RUN apt-add-repository ppa:ondrej/php
RUN apt-get -y install php7.1 php7.1-fpm
RUN apt-get install php7.1-mysql
RUN apt-get -y install nginx
For some reason, I tried to run dockfile inside docker-compose:
version: '3'
services:
web:
build:
context: .
dockerfile: Dockerfile
ports:
- "3011:80"
command: nginx
After I run docker-compose up, I access 127.0.0.1:3011, but nginx is not running.
Seems like nginx haven't been start. Am I doing wrong at this line?
command: nginx