Giter VIP home page Giter VIP logo

nginx-proxy-plone's Introduction

Nginx Proxy Plone

This container runs a nginx:stable-apline image with a reverse proxy to a Plone or Varnish container.

Features

Usage

This container expects that a named Plone instance is already running.

Start a single Nginx server

This will download and start the latest nginx-proxy container, based on Alpine.

$ docker run -p 80:80 -e DOMAIN_NAME=mydomain.com \
                      -e BACKEND=plone-container-name \
                      -e BACKEND_PORT="8080" \
                      docker1.zestsoftware.nl/zestadmin/zest-nginx

This image includes EXPOSE 80 (the default HTTP port). When DNS is setup to point DOMAIN_NAME to the docker machine IP, you can view your Plone Site at http://DOMAIN_NAME:80

Setup in Rancher

In Rancher you can define a stack with a Plone service and then trust on service name resolution by using the service name in the BACKEND variable. e.g. with a service named plone-instance, define a environment variable BACKEND=plone-instance.

For basic hosting use can run this image as is. More advanced setups require building your own image to extend this one.

Building you own image

If you need SSL or a more advanced nginx configuration, like a list of redirects, you should build your own image.

In this image we setup some server defaults for proxying, request size, security headers, etc which are found in defaults.conf

Our server config is stored in nginx.conf and replaces the /etc/nginx/conf.d/default.conf of the official nginx image.

The configuration based on environment variables is done in the entrypoint. In docker-entrypoint.sh you note a simple sed of all variables.

To support dynamic configuration by Rancher or other orchestration tool when creating new containers you should preserve the BACKEND variable.

  • Create a Dockerfile:

    COPY nginx.conf /etc/nginx/conf.d/default.conf
    COPY redirects.conf /etc/nginx/redirects.conf
    
  • Create your custom redirects.conf and nginx.conf by copying them from this image.

  • Build your own image:

    docker build -t zest-nginx-DOMAIN_NAME .

Now you can run your own image or push it to a registry.

TODO

  • SSL configuration

nginx-proxy-plone's People

Contributors

jladage avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.