File tree Expand file tree Collapse file tree 1 file changed +55
-0
lines changed Expand file tree Collapse file tree 1 file changed +55
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : CI
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ pull_request :
8
+ branches :
9
+ - main
10
+
11
+ jobs :
12
+ build :
13
+ runs-on : ubuntu-latest
14
+
15
+ services :
16
+ postgres :
17
+ image : postgres:17.2
18
+ env :
19
+ POSTGRES_DB : dashboard
20
+ POSTGRES_USER : openjs
21
+ POSTGRES_PASSWORD : password
22
+ ports :
23
+ - 5432:5432
24
+ options : >-
25
+ --health-cmd="pg_isready -U openjs"
26
+ --health-interval=10s
27
+ --health-timeout=5s
28
+ --health-retries=5
29
+
30
+ steps :
31
+ - name : Checkout code
32
+ uses : actions/checkout@v3
33
+
34
+ - name : Set up Node.js
35
+ uses : actions/setup-node@v3
36
+ with :
37
+ node-version : ' 22'
38
+
39
+ - name : Install dependencies
40
+ run : npm install
41
+
42
+ - name : Lint files
43
+ run : npm run lint
44
+
45
+ - name : Run migrations
46
+ run : npm run db:migrate
47
+
48
+ - name : Seed database
49
+ run : npm run db:seed
50
+
51
+ - name : Run tests
52
+ run : npm test
53
+
54
+ - name : Stop infrastructure
55
+ run : npm run infra:stop
You can’t perform that action at this time.
0 commit comments