Setup from scratch¶
Here we will got through each step of the setup of the ecodev ecosystem, so that you may install it from scratch, either on your machine or "in production" (e.g. a remote Virtual Machine (VM)).
Dev setup¶
Requirements¶
To work locally, you need docker installed and
- A database. We typically work with PostgreSQL, but any SQL database (e.g. SQLite) will suffice.
- an admin interface to handle the db (you could work without it, but it is such a time saviour in our experience. We adopt here pgAdmin)
- An application π: this is the raison d'Γͺtre of ecodev-app!
So instead of creating your own one from scratch, start from
ecodev-app
as explained below.
How to¶
- 1) To setup the db and the admin interface, follow this part of the documentation. Take the environment variables from the production setup and then skip to the dev part.
- 2) follow this section and then this section of the ecodev-app documentation.
You should then have a locally working ecodev-app plugged into it's sql db! Congrats! π₯°
Prod setup¶
Requirements¶
To work on a remote VM, you need
- a VM (duh π )
- A reverse-proxy: our choice goes for Traefik.
- a db: our choice goes for PostgreSQL
- an admin interface to handle the db (you could work without it, but it is such a time saviour in our experience. We adopt here pgAdmin)
-
monitoring tools. As discussed elsewhere in this documentation, we favored simplicity over the popular prometheus/grafana stack: else we advocate
- uptime-kuma for alerting and
- Dozzle for monitoring.
-
An application π: this is the raison d'Γͺtre of ecodev-app!
How to¶
- 1) Setup your VM with Ubuntu (rent it from your favourite cloud provider and follow their setup tutorials), then install
ecodev-infra
required OS packages (mostly docker) using this ecodev-infra documentation page. - 2) We strongly encourage you to read this ecodev-infra documentation on security.
- 3) To setup traefik, go read this
- 4) To setup the db and the admin interface, follow this part of the documentation. Skip the last section (relate to local deployment)
- 5) To setup the monitoring/alerting tools, go read this and this.
- 6) follow this section and then this section of the ecodev-app documentation.
You should have a working, secured application on the cloud! π. To update it, simply run git pull
when needs be (and do not forget to rebuild the image first if you updated the
dependencies since last build! π)