catchpy - nmaekawa/hx-provision GitHub Wiki

Details on how to use hx-provision to config a catchpy vagrant instance. The following directions pick up from the setup in Home_.

disclaimer

For demo purposes only! provided only to show how to setup a catchpy vagrant installation and support to this repo is OUT-OF-SCOPE at this time.

vagrant instances

To start the catchpy and database vagrant instances:

(venv) $> vagrant up catchpy dbserver

You can login into box like below, so the ssh host key fingerprint is stored in ~/.ssh/known_hosts. This helps with ansible-playbook when installing catchpy:

$> ssh [email protected] -i ~/.vagrant.d/insecure_private_key
...

provision the instances

Run:

# apply playbook catchpy_play.yml
(venv) $> ansible-playbook -i hosts/vagrant_catchpy.ini catchpy_play.yml --extra-vars project_name=catchpy

If all goes well, you should be able to see the django-admin ui with login user:password

And check the catchpy api:

To create auth tokens, please refer to the catchpy repo readme:

the default configuration

Running the provisioning like in the previous step, renders a default install:

  • postgres database catchpy, owned by user catchpy with password catchpy
  • root dir for catchpy is /opt/hx/catchpy; in there you'll find the virtualenv, logs, catchpy repo clone, config/dotenv files
  • catchpy django app will run with gunicorn; check /opt/hx/catchpy/venv/bin/gunicorn_start
  • django admin user is 'user:password'
  • nginx in vagrant uses HTTP

logs, restarting services

Django app logs are redirected to /var/log/syslog

The django app is setup to use gunicorn and supervisor so if you need to restart the webapp do:

$> sudo supervisorctl restart catchpy

---eop

⚠️ **GitHub.com Fallback** ⚠️