Sign inSign up

meural/python

By meural

•Updated almost 7 years ago

Base images for Meural builds.

Image
0

4.0K

meural/python repository overview

⁠Docker Containers

This repo stores the build instructions for generic or base-level containers. To make changes, commit changes to master. Dockerhub⁠ will detect the changes, build, and host the new containers. This is convient but dangerous. Make sure that everything is right before pushing to master. An error in these files will cause deployment of every Meural property to fail.

⁠Python

Available at: meural/python

Tags: meural/python:2-imaging, meural/python:3

This container builds the base-image for the Meural's API to run in. It builds on python:2-slim-stretch and adds needed system-level libraries such as ffmpeg and imagemagick.

⁠Usage

This container is used in the api repo to build Meural's API application. See the django/Dockerfile or .circleci/config.yml to see how it is actually used.

⁠Nginx

Available at: meural/nginx

Tags: meural/nginx:latest

This is a generic nginx config that can be placed in front of all of our services if they meet the following requirements.

  • Exposed to nginx on hostname application and port 8000
  • Expose static files at /var/www/static/

The following example docker-compose.yml file meets these requirements.

version: '2'

services:
  application:
    image: ...
      ...
    volumes:
      - static:/var/www/static
    ports:
      - "8000"
  nginx:
    image: **this_very_image**:latest
      ...
    ports:
      - "80"
      - "443"
    volumes:
      - static:/var/www/static:ro
    links:
      - application
volumes:
  static:
    driver: local
⁠Features
  • Redirects http to https
  • Serves gzipped static assets
  • Gzips application/json responses
  • Limits max upload size to 1gb
  • Sets number of workers by detecting number of cpu cores
  • Supports AWS /health_check endpoint
  • Serves static directory at / and /static/
  • Caches and gzips next bundles
⁠Usage

Use it in a docker-compose like the one above.

Tag summary

Content type

Image

Digest

Size

397.8 MB

Last updated

almost 7 years ago

docker pull meural/python:3-imaging