Coder Social home page Coder Social logo

strichliste-docker's Introduction

strichliste-docker - A Strichliste Docker Container

This is a docker container for the strichliste using the strichliste frontend and backend bundle, a MariaDB database and a the Telegram Bot strichliste-telegram.

Usage

  • Clone this repository.
  • Create settings.env from template and change values.
  • Create docker-compose.yml from template and change for your needs (remove treafik for example).
  • Setup initial database.

Setup initial database

After configuring the environment variables you can start the container and create the inital database schema with the following command:

./../bin/console doctrine:schema:create

(you might need to wait a bit for the database to start up, the command will tell you if it succeeded or not)

Templates

Example settings.env configuration:

DB_HOST=db
MYSQL_ROOT_PASSWORD=
MYSQL_DATABASE=strichliste
MYSQL_USER=strichliste
MYSQL_PASSWORD=
DATABASE_URL=mysql://strichliste:<changeme>@db/strichliste

Example docker-compose configuration:

version: "3.8"

services:

  web:
    build: ./data/web
    env_file:
      - settings.env
    networks:
      - reverse-proxy
      - internal
    volumes:
      - ./data/web/services.yaml:/var/www/html/config/services.yaml
      - ./data/web/strichliste.yaml:/var/www/html/config/strichliste.yaml
      - ./data/web/doctrine.yaml:/var/www/html/config/packages/doctrine.yaml
    labels:
      - "traefik.enable=true"
      - "traefik.http.routers.strichliste.rule=Host(`myhostname.fqdn.local`)"
      - "traefik.http.routers.strichliste.entryPoints=https"
      - "traefik.http.routers.strichliste.tls=true"
      - "traefik.http.services.strichliste.loadbalancer.server.scheme=http"
      - "traefik.http.services.strichliste.loadbalancer.server.port=80"
    restart: unless-stopped
    depends_on: 
      - db
  db:
    image: mariadb
    restart: unless-stopped
    env_file:
      - settings.env
    volumes:
      - ./data/db:/var/lib/mysql
    networks:
      - internal

  telegram:
    build: ./data/telegram
    restart: unless-stopped
    volumes:
      - ./data/telegram/authorizedUsers.json:/usr/src/app/authorizedUsers.json
      - ./data/telegram/config.py:/usr/src/app/config.py
    networks:
      - internal

networks:
  reverse-proxy:
    external: true
  internal:
    external: false

strichliste-docker's People

Contributors

foorschtbar avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  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.