1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-07-19 13:19:44 +02:00

Merge pull request #12 from wheresvic/master

Add dev documentation and local db server
This commit is contained in:
Maksim Eltyshev 2020-05-06 19:07:23 +05:00 committed by GitHub
commit 0519df4e4d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 27 additions and 1 deletions

View file

@ -56,7 +56,16 @@ cd planka
npm install
```
Create a database and edit `DATABASE_URL` in `.env` file. Then initialize it:
Either use a local db or start the provided development db: `docker-compose -f docker-compose-dev.yml up`
Create a db user by first logging into the db `psql -U postgres -h localhost` and then:
```
create user [username]; --create a role for your local username
grant postgres to [username]; --grant all privileges to this user
```
Finally, create a database and edit `DATABASE_URL` in `.env` file. Then initialize it:
```
npm run server:db:init

17
docker-compose-dev.yml Normal file
View file

@ -0,0 +1,17 @@
version: '3'
services:
postgres:
image: postgres:alpine
restart: unless-stopped
volumes:
- db-data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=planka
- POSTGRES_HOST_AUTH_METHOD=trust
ports:
- "5432:5432"
expose:
- "5432"
volumes:
db-data: