Skip to content

Commit 81aeac0

Browse files
chore(db): add start scripts
1 parent 85b95b6 commit 81aeac0

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

Makefile.toml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,22 @@ args = ["serve"]
3232
# rm -rf dist
3333
# '''
3434

35+
# local db
36+
[tasks.db-start]
37+
workspace = false
38+
script_runner = "@shell"
39+
script = '''
40+
docker run -d --name devbcn-workshop -p 5432:5432 -e POSTGRES_PASSWORD=postgres -e POSTGRES_USER=postgres -e POSTGRES_DB=devbcn postgres
41+
'''
42+
43+
[tasks.db-stop]
44+
workspace = false
45+
script_runner = "@shell"
46+
script = '''
47+
docker stop postgres
48+
docker rm postgres
49+
'''
50+
3551
# general tasks
3652
[tasks.clippy]
3753
workspace = false

0 commit comments

Comments
 (0)