Public Repository

Last pushed: a year ago
Short Description
Ubuntu 14.4 + Nginx 1.8
Full Description

Ubuntu 14.4 + Nginx 1.8

for production environment

  • Exposed ports: 80

Docker compose example

version: "2"

services:
  ubuntu14_nginx18_php55:
    image: imaghonet/ubuntu14_nginx18_php55
    links:
      - db
      - mc
    volumes:
      - your/path/to/nginx.conf:/etc/nginx/nginx.conf  
      - your/path/to/service.conf:/etc/nginx/conf.d/service.conf
      - your/path/to/project/root:/opt/project

    db:
      image: mongo
      volumes:
        - /tmp/db:/data/db

    mc:
      image: memcached

Docker file

# Pull base image.
FROM ubuntu:trusty

LABEL pl.imagho.image.version="1.1" \
      pl.imagho.image.description="Ubuntu 14.4, Nginx 1.8" \
      pl.imagho.image.os="ubuntu14" \
      pl.imagho.image.webserver.name="nginx" \
      pl.imagho.image.webserver.version="1.8"

MAINTAINER imaghonet <sysops@imagho.net>

# Install Nginx.
RUN \
  apt-get install -y software-properties-common && \
  add-apt-repository -y ppa:nginx/stable && \
  apt-get update && \
  apt-get upgrade -y && \
  apt-get install -y nginx && \
  rm -rf /var/lib/apt/lists/* && \
  echo "\ndaemon off;" >> /etc/nginx/nginx.conf && \
  chown -R www-data:www-data /var/lib/nginx

# Define working directory.
WORKDIR /etc/nginx

# Define default command.
CMD ["nginx"]

# Expose ports.
EXPOSE 80
Docker Pull Command
Owner
imaghonet

Comments (0)