GraphQL API and database interface for Gardenbuilder
Made with Django, Postgres and GraphQL
Follow these steps to set up and initialize a virtual environment. From inside the project root:
python3 -m venv env # Set up virtual env
source env/bin/activate # Activate virtual env
pip install -r requirements.txt # Install requirements
You'll need to also set up a postgresql database named gardenbuilder. I would follow the directions here.
Alternatively, you could run postgresql locally using docker: docker run -e POSTGRES_USER=root -e POSTGRES_PASSWORD=secret -e POSTGRES_DB=gardenbuilder -p 127.0.0.1:5432:5432/tcp library/postgres
Finally, you'll need to add the following into the src/config/.env
:
DB_NAME=gardenbuilder
DB_USER=root
DB_PASSWORD=secret
DB_HOST_LOCAL=localhost
DB_PORT=5432
DJANGO_SECRET_KEY=secretKeyHere
python src/manage.py migrate
python src/manage.py runserver
Then navigate to localhost:8000/graphql. You should see the graphiQL editor and be able to write queries like
query {
gardens {
name
}
}
cd src
python manage.py test
We would love some help, especially for Hacktoberfest!
There are a number of issues that we would love your help with. Many of them are fairly easy and are tagged as good first issue
. Most are things that I (capndave), just haven't gotten around to yet. Feel free to fork, work on, and submit a pull request for anything you see an issue for.
If the issue you want to work on is a spelling or grammar mistake, or a documentation issue, feel free to make a pull request with your changes (without submitting an issue first)
For all other changes, please submit an issue before submitting a pull request! Please reference a given issue in cases where a related pull request is made.
If you are interested in ok-ing pull requests, co-managing this repo or anything else beyond occasional contributions, please email me at [email protected]. I'd love your help!
Questions? Feel free to contact Dave at [email protected]
.