-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #99 from team-crews/dev
- Loading branch information
Showing
168 changed files
with
8,651 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
name: Bug fix | ||
about: fix bug | ||
title: 'fix: ' | ||
labels: bug | ||
assignees: jongmee | ||
|
||
--- | ||
|
||
## Problem 🐞 | ||
|
||
>문제 상황을 설명해주세요 | ||
## Progress 🐢 | ||
|
||
- [ ] todo1 | ||
- [ ] todo2 | ||
- [ ] todo3 | ||
|
||
## Help ❗️ | ||
|
||
아직 못 고쳤거나, 왜 고쳐진지 모르겠다면 작성해주세요. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
name: Feature | ||
about: new feature | ||
title: 'feat: ' | ||
labels: enhancement | ||
assignees: jongmee | ||
|
||
--- | ||
|
||
## Description ✏️ | ||
|
||
>description | ||
## Progress 🐢 | ||
|
||
- [ ] todo1 | ||
- [ ] todo2 | ||
- [ ] todo3 | ||
|
||
## Need to improve 🥕 | ||
|
||
추후 개선해야 할 사항이 있다면 작성해주세요. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
## Description 📒 | ||
|
||
>description | ||
## Issue 💬 | ||
|
||
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
name: crews backend deploy | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.ACTION_TOKEN }} | ||
submodules: true | ||
|
||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
|
||
- name: Set up MySQL | ||
uses: mirromutth/[email protected] | ||
with: | ||
mysql database: 'crews' | ||
mysql user: ${{ secrets.TEST_DB_USERNAME }} | ||
mysql password: ${{ secrets.TEST_DB_PASSWORD }} | ||
|
||
- name: Run Test And Create API Documentation | ||
run: ./gradlew openapi3 | ||
|
||
- name: Build with Gradle | ||
run: ./gradlew bootJar -x test | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Login to Docker Hub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
|
||
- name: Build Docker Image And Push | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
push: true | ||
tags: ${{ secrets.DOCKER_PROD_SERVER_IMAGE_NAME }} | ||
platforms: | | ||
linux/amd64 | ||
linux/arm64 | ||
deploy: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: deploy | ||
uses: appleboy/ssh-action@master | ||
with: | ||
host: ${{ secrets.HOST }} | ||
username: ubuntu | ||
key: ${{ secrets.KEY }} | ||
script: | | ||
cd /home/ubuntu | ||
sudo chmod 666 /var/run/docker.sock | ||
docker rm -f $(docker ps -qa) | ||
docker pull ${{ secrets.DOCKER_PROD_SERVER_IMAGE_NAME }} | ||
docker run -d -p 8080:8080 --name crews-server \ | ||
-e JAVA_OPTS="-XX:InitialRAMPercentage=70.0 -XX:MaxRAMPercentage=70.0" \ | ||
-e SPRING_PROFILES_ACTIVE=prod \ | ||
${{ secrets.DOCKER_PROD_SERVER_IMAGE_NAME }} | ||
docker image prune -f | ||
docker volume prune -f |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: crews backend ci | ||
|
||
on: | ||
pull_request: | ||
branches: [ "dev", "main" ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.ACTION_TOKEN }} | ||
submodules: true | ||
|
||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
|
||
- name: Set up MySQL | ||
uses: mirromutth/[email protected] | ||
with: | ||
mysql database: 'crews' | ||
mysql user: ${{ secrets.TEST_DB_USERNAME }} | ||
mysql password: ${{ secrets.TEST_DB_PASSWORD }} | ||
|
||
- name: Set up Redis | ||
uses: supercharge/[email protected] | ||
with: | ||
redis-port: 36379 | ||
|
||
- name: Run Test | ||
run: ./gradlew clean test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
name: crews backend development version distribute | ||
|
||
on: | ||
push: | ||
branches: [ "dev" ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.ACTION_TOKEN }} | ||
submodules: true | ||
|
||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
|
||
- name: Set up MySQL | ||
uses: mirromutth/[email protected] | ||
with: | ||
mysql database: 'crews' | ||
mysql user: ${{ secrets.TEST_DB_USERNAME }} | ||
mysql password: ${{ secrets.TEST_DB_PASSWORD }} | ||
|
||
- name: Set up Redis | ||
uses: supercharge/[email protected] | ||
with: | ||
redis-port: 36379 | ||
|
||
- name: Run Test And Create API Documentation | ||
run: ./gradlew openapi3 | ||
|
||
- name: Build with Gradle | ||
run: ./gradlew bootJar -x test | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Login to Docker Hub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
|
||
- name: Build Docker Image And Push | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
push: true | ||
tags: ${{ secrets.DOCKER_SERVER_IMAGE_NAME }} | ||
platforms: | | ||
linux/amd64 | ||
linux/arm64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: release tag | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- uses: actions/checkout@v2 | ||
|
||
- name: Extract Version Information | ||
run: echo "##[set-output name=version;]$(echo '${{ github.event.head_commit.message }}' | egrep -o '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}')" | ||
id: extract_version_name | ||
|
||
- name: Create Release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.ACTION_TOKEN }} | ||
with: | ||
tag_name: ${{ steps.extract_version_name.outputs.version }} | ||
release_name: ${{ steps.extract_version_name.outputs.version }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
HELP.md | ||
.gradle | ||
build/ | ||
!gradle/wrapper/gradle-wrapper.jar | ||
!**/src/main/**/build/ | ||
!**/src/test/**/build/ | ||
|
||
### STS ### | ||
.apt_generated | ||
.classpath | ||
.factorypath | ||
.project | ||
.settings | ||
.springBeans | ||
.sts4-cache | ||
bin/ | ||
!**/src/main/**/bin/ | ||
!**/src/test/**/bin/ | ||
|
||
### IntelliJ IDEA ### | ||
.idea | ||
*.iws | ||
*.iml | ||
*.ipr | ||
out/ | ||
!**/src/main/**/out/ | ||
!**/src/test/**/out/ | ||
|
||
### NetBeans ### | ||
/nbproject/private/ | ||
/nbbuild/ | ||
/dist/ | ||
/nbdist/ | ||
/.nb-gradle/ | ||
|
||
### VS Code ### | ||
.vscode/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[submodule "src/main/resources/config"] | ||
path = src/main/resources/config | ||
url = https://github.com/team-crews/crews-config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
FROM openjdk:17 | ||
ARG JAR_FILE=/build/libs/*.jar | ||
COPY ${JAR_FILE} app.jar | ||
ENTRYPOINT ["sh", "-c", "java ${JAVA_OPTS} -jar /app.jar"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2024 Crews | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
Oops, something went wrong.