Public Repository

Last pushed: 2 years ago
Short Description
Serves as a reverse proxy, with automated ssl certificate generation
Full Description

jsninja-service-ssl

What does it do?

SSL Terminator with letsencrypt renewal script

Serves as a reverse proxy, with automated ssl certificate generation

How do I set it up?

The best way to integrate this container into your infrastructure is to use docker-compse. To that end here are some basic setup instructions.

docker-compse.yml file

version: '2'
services:
    chat-service:
        build: services/chat-service
    ssl-service:
        build: services/ssl-service
        depends_on:
            - chat-service
        environment:
            - DOMAINS=chat.thejs.ninja
            - SERVICE_HOST=chat-service
            - SERVICE_PORT=3000
        ports:
            - 80:80
            - 443:443
        volumes:
            - ssl-data-store-certs:/etc/letsencrypt
            - ssl-data-store-configs:/etc/nginx/conf.d
            - ssl-data-store-html:/var/www
volumes:
    ssl-data-store-certs:
        driver: local
    ssl-data-store-configs:
        driver: local
    ssl-data-store-html:
        driver: local

Environment variables

DOMAINS=chat.thejs.ninja
SERVICE_HOST=chat-service
SERVICE_PORT=3000

Commands

These commands are based on the docker-compse file above

Initial setup

# Create your environment
docker-compse up -d

# Do a dry run, checking that everything went ok
docker-compse run ssl-service generate

# Do a real run, this will create certificates, etc
docker-compse run ssl-service generate --real

Delete certificates / configs

# Delete configs
docker-compse run ssl-service generate delete conf

# Delete certificates
docker-compse run ssl-service generate delete cert

# Delete both
docker-compse run ssl-service generate delete
Docker Pull Command
Owner
jsninja

Comments (0)