just: add db{start,stop} targets [skip ci]
This commit is contained in:
parent
0a5d4e7d30
commit
6c061fb94f
15
justfile
15
justfile
@ -28,3 +28,18 @@ dev: build run
|
|||||||
# generate code based on ent schemas.
|
# generate code based on ent schemas.
|
||||||
gen:
|
gen:
|
||||||
go generate -v ./ent
|
go generate -v ./ent
|
||||||
|
|
||||||
|
# start pg.
|
||||||
|
dbstart:
|
||||||
|
podman run \
|
||||||
|
--name pg \
|
||||||
|
--rm \
|
||||||
|
-it \
|
||||||
|
-e POSTGRES_PASSWORD=postgres \
|
||||||
|
-v $PWD/tmp/db:/var/lib/postgres/data \
|
||||||
|
-p 127.0.0.1:5432:5432 \
|
||||||
|
docker.io/library/postgres:15.2-alpine3.17
|
||||||
|
|
||||||
|
# stop pg.
|
||||||
|
dbstop:
|
||||||
|
podman stop pg
|
||||||
|
Loading…
Reference in New Issue
Block a user