Files
mealie/docs/docs/contributors/developers-guide/starting-dev-server.md
Hayden c196445e61 feature/additional-db (#371)
* add support for setting db_url

* fix tests

* add db_username/password env variables

* init db if super user doesn't exist

* fix tests

* fix tests

* set SQLite default DB_URL

* don't run tests on draft PRs

* add lint/black tests

* add test-all

* spell check settings

* black/flake8

* check format fail

* new badges

* rename workflow

* fix formatting

* remove white-space

* test connection arguments for pg

* format

* add new values to template

* format

* remove old script

* monkeypatch test db

* working docker-compose for postgres

* update docs

* test pg workflow

* format

* add driver

* install w/ poetry

* setup container

* change image

* set database to localhost

* update tests

* set url

* fix url path

* disable cache

* database init

* bust cache

* get by name

Co-authored-by: hay-kot <hay-kot@pm.me>
2021-05-01 13:35:57 -08:00

1.6 KiB

Development: Getting Started

After reading through the Code Contributions Guide and forking the repo you can start working. This project is developed with 🐳 docker and as such you will be greatly aided by using docker for development. It's not necessary but it is helpful.

With Docker

Prerequisites

  • Docker
  • docker-compose

You can easily start the development stack by running make docker-dev in the root of the project directory. This will run and build the docker-compose.dev.yml file.

Without Docker

Prerequisites

  • Python 3.9+
  • Poetry
  • Nodejs
  • npm

Once the prerequisites are installed you can cd into the project base directory and run make setup to install the python and node dependencies. Once that is complete you can run make backend and make vue to start the backend and frontend servers.

Make File Reference

make setup installs python and node dependencies

make backend Starts the backend server on port 9000

make vue Starts the frontend server on port 8080

make mdocs Starts the documentation server on port 8000

make docker-dev Builds docker-compose.dev.yml

make docker-prod Builds docker-compose.yml to test for production

Before you Commit!

Before you commit any changes on the backend/python side you'll want to run make format to format all the code with black. make lint to check with flake8, and make test to run pytests. You can also use make test-all to run both lint and test.

Run into another issue? Ask for help on discord