Lady Lilia's website
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Nikola Forró e4fb3e9906
Change default page size to 20 items
7 years ago
api Change __API_KEY__ to $API_KEY in API docs for consistency 7 years ago
cms Add Grav CMS, embed Quotes app into it 7 years ago
ng-app Change default page size to 20 items 7 years ago
nginx Add Grav CMS, embed Quotes app into it 7 years ago
Dockerfile Rename frontend to ng-app 7 years ago
LICENSE Add LICENSE 7 years ago
README.md Add README 7 years ago
docker-compose.yaml.example Add example docker-compose config file 7 years ago

README.md

ladylilia.com

Project structure

  • api - Flask application implementing RESTful API for querying/manipulating database of quotes
  • cms - Grav CMS (Content Management System)
  • ng-app - Angular application for browsing quotes
  • nginx - Configuration of NGINX web server

Deployment

This project consists of 3 container images (api, cms and nginx), that depend on each other - they need to run simultaneously and share certain data between themselves.

Easiest way how to manage that is using docker-compose. Just copy docker-compose.yaml.example into docker-compose.yaml, make necessary adjustments and fire it all up with:

docker-compose up -d

API key generation

API key is needed for POST, PUT and DELETE API methods.

If the api container is running, the key can be generated like this:

docker exec $API_CONTAINER_NAME python generate_api_key.py $USERNAME $EXPIRATION_TIME_IN_SECONDS