Skip to content

Commit

Permalink
WebApp CI 추가 (#17)
Browse files Browse the repository at this point in the history
* Client CI 추가

* Github Actions 리팩토링

* Github Actions 리팩토링

* Github Actions 리팩토링
  • Loading branch information
seungh0 authored Jul 2, 2024
1 parent 61e1682 commit ac28b9f
Show file tree
Hide file tree
Showing 4 changed files with 92 additions and 104 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/ci-client.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: "CI (Client)"
on:
pull_request:
branches:
- main
types:
- opened
- synchronize
- reopened
push:
branches:
- main
workflow_dispatch:

env:
CI: ''
jobs:
ci:
name: Build on Node
runs-on: ubuntu-latest
strategy:
matrix:
node: [ 14, 16, 18 ]
steps:
- name: checkout@v4
uses: actions/checkout@v4

- name: Use Node ${{ matrix.node }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}

- name: Cache node modules
id: cache-npm
uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Install and Build
run: |
npm install
npm run build
working-directory: cadio-web/src/main/webapp
40 changes: 40 additions & 0 deletions .github/workflows/ci-server.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: "CI (Server)"

on:
pull_request:
branches:
- main
types:
- opened
- synchronize
- reopened
push:
branches:
- main
workflow_dispatch:

jobs:
ci:
name: Build on Cassandra
runs-on: ubuntu-latest
strategy:
matrix:
cassandra-version: [ '4.0', '4.1', '5.0' ]
steps:
- name: checkout@v4
uses: actions/checkout@v4

- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: 21
distribution: adopt
cache: gradle
timeout-minutes: 3

- name: Use Cassandra ${{ matrix.cassandra-version }}
run: docker compose -f "docker/docker-compose-cassandra-${{ matrix.cassandra-version }}.yml" up -d --build --wait
timeout-minutes: 3

- name: Build
run: ./gradlew build
104 changes: 0 additions & 104 deletions .github/workflows/ci.yml

This file was deleted.

1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,4 @@ bin/
.idea

node_modules/
**/build/

0 comments on commit ac28b9f

Please sign in to comment.