Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit 3ade7eb

Browse files
committed
ci(actions): seperate job by backend/front
1 parent c88de83 commit 3ade7eb

File tree

1 file changed

+10
-38
lines changed

1 file changed

+10
-38
lines changed

.github/workflows/ci.yml

Lines changed: 10 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
branches: [master, dev]
88

99
jobs:
10-
setup-server:
10+
setup-backend-server:
1111
name: Setup Backend Server
1212
runs-on: ubuntu-latest
1313
services:
@@ -51,6 +51,15 @@ jobs:
5151
run: MIX_ENV=ci mix run priv/mock/cps_seeds.exs > /dev/null
5252
- name: ls dir
5353
run: ls
54+
- name: Run Backend Server
55+
working-directory: ./backend_server
56+
run: MIX_ENV=ci mix phx.server &
57+
58+
setup-front:
59+
name: Setup Web Front
60+
runs-on: ubuntu-latest
61+
needs: setup-server
62+
steps:
5463
- uses: actions/checkout@v2
5564
with:
5665
fetch-depth: 0
@@ -78,43 +87,6 @@ jobs:
7887
- name: ls ..
7988
working-directory: ./frontend_server
8089
run: ls ..; ls ../backend_server
81-
- name: Run Backend Server
82-
working-directory: ./backend_server
83-
run: MIX_ENV=ci mix phx.server &
8490
- name: Run Tests
8591
working-directory: ./frontend_server
8692
run: npm run test:ci
87-
# setup-front:
88-
# name: Setup Web Front
89-
# runs-on: ubuntu-latest
90-
# needs: setup-server
91-
# steps:
92-
# - uses: actions/checkout@v2
93-
# - uses: actions/setup-node@v2
94-
# with:
95-
# node-version: '12'
96-
# - name: checkout
97-
# uses: actions/checkout@v2
98-
# with:
99-
# fetch-depth: 0
100-
# # - name: Install Packages
101-
# # run: yarn
102-
# - name: Setup config tools
103-
# run: chmod +x ./utils/bin/jq-linux; ./utils/bin/jq-linux -s '.[0] * .[1]' config/config.json config/config.ci.json > /tmp/config.json; cp /tmp/config.json ./config/config.json
104-
# # - name: Build Project
105-
# # run: npm run build.ci
106-
# # - name: Check Bundle Size
107-
# # run: BUNDLEWATCH_GITHUB_TOKEN=${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }} npm run size.check
108-
# - name: Set up Elixir and OTP
109-
# uses: actions/setup-elixir@v1
110-
# with:
111-
# elixir-version: '1.10.3' # Define the elixir version [required]
112-
# otp-version: '22.3' # Define the OTP version [required]
113-
# - name: debug dir
114-
# run: ls
115-
# - name: debug server dir
116-
# run: ls ./backend_server
117-
# - name: Run Backend Server
118-
# run: cd backend_server; MIX_ENV=ci mix phx.server &
119-
# # - name: Run Tests
120-
# run: npm run test:ci

0 commit comments

Comments
 (0)