-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weโll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature/#10] : CI/CD setting #13
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
7b87e57
#10 [DEL] : remove test token
sohyun127 b9304d4
#10 [DEL] : remove jlleitschuh ktlint plugin
sohyun127 a482285
#10 [SETTING] : add keystore.properties to .gitignore
sohyun127 870fbe4
#10 [SETTING] : add .gitkeep to keystore package
sohyun127 8de047f
#10 [SETTING] : set keystore for management
sohyun127 238f7f5
#10 [SETTING] : configure CI settings
sohyun127 a70049a
#10 [SETTING] : change CI to be allowed for PRs only
sohyun127 790d3eb
#10 [SETTING] : configure CD settings
sohyun127 208e073
#10 [SETTING] : set up auto_assign
sohyun127 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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,2 @@ | ||
addReviewers: false | ||
addAssignees: author |
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
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,111 @@ | ||
name: Wable Release Note | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
working-directory: . | ||
|
||
jobs: | ||
build: | ||
name: Generate Release APK, Note | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: set up JDK 17 | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: "zulu" | ||
java-version: 17 | ||
|
||
- name: Setup Android SDK | ||
uses: android-actions/setup-android@v3 | ||
|
||
- name: Add Network Base Url | ||
env: | ||
WABLE_DEV_BASE_URL: ${{ secrets.WABLE_DEV_BASE_URL }} | ||
WABLE_REL_BASE_URL: ${{ secrets.WABLE_REL_BASE_URL }} | ||
run: | | ||
echo wable.dev.base.url=$WABLE_DEV_BASE_URL >> ./local.properties | ||
echo wable.rel.base.url=$WABLE_REL_BASE_URL >> ./local.properties | ||
|
||
- name: Access Google Services JSON | ||
env: | ||
GOOGLE_SERVICES_JSON: ${{ secrets.GOOGLE_SERVICES_JSON }} | ||
run: echo $GOOGLE_SERVICES_JSON | base64 -di > ./app/google-services.json | ||
|
||
- name: Access Keystore | ||
env: | ||
DEBUG_KEY_STORE: ${{ secrets.DEBUG_KEY_STORE }} | ||
RELEASE_JKS: ${{ secrets.RELEASE_JKS }} | ||
RELEASE_KEY_STORE_PROPERTIES: ${{ secrets.RELEASE_KEY_STORE_PROPERTIES }} | ||
run: | | ||
echo $RELEASE_JKS | base64 -di > ./app/keystore/release.jks | ||
echo $RELEASE_KEY_STORE_PROPERTIES | base64 -di > ./keystore.properties | ||
echo $DEBUG_KEY_STORE | base64 -di > ./app/keystore/debug.keystore | ||
|
||
- name: Cache Gradle packages | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
~/.gradle/caches | ||
~/.gradle/wrapper | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', '**/buildSrc/**/*.kt') }} | ||
restore-keys: | | ||
${{ runner.os }}-gradle- | ||
|
||
- name: Grant execute permission for gradlew | ||
run: chmod +x gradlew | ||
|
||
- name: Extract Version Name | ||
run: | | ||
VERSION=$(grep -oP 'appVersion\s*=\s*"\K[0-9]+\.[0-9]+\.[0-9]+' gradle/libs.versions.toml) | ||
echo "##[set-output name=version;]v$VERSION" | ||
id: extract_version | ||
|
||
- name: Build release APK | ||
run: ./gradlew assembleRelease --stacktrace | ||
|
||
- name: Upload Release Build to APK | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: release-apk | ||
path: app/build/outputs/apk/release/ | ||
if-no-files-found: error | ||
|
||
- name: Create Github Release note | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
tag_name: ${{ steps.extract_version.outputs.version }} | ||
release_name: ${{ steps.extract_version.outputs.version }} | ||
generate_release_notes: true | ||
files: | | ||
app/build/outputs/apk/release/app-release.apk` | ||
|
||
- name: On Success, Notify in Slack | ||
if: ${{ success() }} | ||
uses: MeilCli/slack-upload-file@v3 | ||
with: | ||
slack_token: ${{ secrets.SLACK_BOT_TOKEN }} | ||
channel_id: ${{ secrets.SLACK_GENERAL_CHANNEL_ID }} | ||
file_path: 'app/build/outputs/apk/release/app-release.apk' | ||
file_name: 'WABLE-ANDROID.apk' | ||
file_type: 'apk' | ||
initial_comment: '๐ ์ต์ข Release๊ฐ ์๋ฃ๋์์ต๋๋ค ๐' | ||
|
||
- name: On Failed, Notify in Slack | ||
if: ${{ failure() }} | ||
uses: rtCamp/action-slack-notify@v2 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }} | ||
SLACK_TITLE: '๐ซ Release PR check Failed ๐ซ' | ||
SLACK_COLOR: '#FF0000' | ||
MSG_MINIMAL: true | ||
SLACK_USERNAME: Wable Android | ||
SLACK_MESSAGE: '๏ธ๐ซโ ๏ธ Release PR ์๋ฌ ๏ธโ ๏ธ๐ซ' |
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,96 @@ | ||
name: Wable Release Test | ||
|
||
on: | ||
pull_request: | ||
branches: [ main ] | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
working-directory: . | ||
|
||
jobs: | ||
build: | ||
name: Release Test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: set up JDK 17 | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: "zulu" | ||
java-version: 17 | ||
|
||
- name: Setup Android SDK | ||
uses: android-actions/setup-android@v3 | ||
|
||
- name: Add Network Base Url | ||
env: | ||
WABLE_DEV_BASE_URL: ${{ secrets.WABLE_DEV_BASE_URL }} | ||
WABLE_REL_BASE_URL: ${{ secrets.WABLE_REL_BASE_URL }} | ||
run: | | ||
echo wable.dev.base.url=$WABLE_DEV_BASE_URL >> ./local.properties | ||
echo wable.rel.base.url=$WABLE_REL_BASE_URL >> ./local.properties | ||
|
||
- name: Access Google Services JSON | ||
env: | ||
GOOGLE_SERVICES_JSON: ${{ secrets.GOOGLE_SERVICES_JSON }} | ||
run: echo $GOOGLE_SERVICES_JSON | base64 -di > ./app/google-services.json | ||
|
||
- name: Access Keystore | ||
env: | ||
DEBUG_KEY_STORE: ${{ secrets.DEBUG_KEY_STORE }} | ||
RELEASE_JKS: ${{ secrets.RELEASE_JKS }} | ||
RELEASE_KEY_STORE_PROPERTIES: ${{ secrets.RELEASE_KEY_STORE_PROPERTIES }} | ||
run: | | ||
echo $RELEASE_JKS | base64 -di > ./app/keystore/release.jks | ||
echo $RELEASE_KEY_STORE_PROPERTIES | base64 -di > ./keystore.properties | ||
echo $DEBUG_KEY_STORE | base64 -di > ./app/keystore/debug.keystore | ||
|
||
- name: Cache Gradle packages | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
~/.gradle/caches | ||
~/.gradle/wrapper | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', '**/buildSrc/**/*.kt') }} | ||
restore-keys: | | ||
${{ runner.os }}-gradle- | ||
|
||
- name: Grant execute permission for gradlew | ||
run: chmod +x gradlew | ||
|
||
- name: Build debug APK | ||
run: ./gradlew assembleDebug --stacktrace | ||
|
||
- name: Upload debug Build to APK | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: debug-apk | ||
path: app/build/outputs/apk/debug/ | ||
if-no-files-found: error | ||
|
||
- name: On Success, Notify in Slack | ||
if: ${{ success() }} | ||
uses: MeilCli/slack-upload-file@v3 | ||
with: | ||
slack_token: ${{ secrets.SLACK_BOT_TOKEN }} | ||
channel_id: ${{ secrets.SLACK_GENERAL_CHANNEL_ID }} | ||
file_path: 'app/build/outputs/apk/debug/app-debug.apk' | ||
file_name: 'WABLE-ANDROID.apk' | ||
file_type: 'apk' | ||
initial_comment: '๐ Release Test๊ฐ ์๋ฃ๋์์ต๋๋ค ๐' | ||
|
||
- name: On Failed, Notify in Slack | ||
if: ${{ failure() }} | ||
uses: rtCamp/action-slack-notify@v2 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }} | ||
SLACK_TITLE: '๐ซ Release PR check Failed ๐ซ' | ||
SLACK_COLOR: '#FF0000' | ||
MSG_MINIMAL: true | ||
SLACK_USERNAME: Wable Android | ||
SLACK_MESSAGE: '๏ธ๐ซโ ๏ธ Release PR ์๋ฌ ๏ธโ ๏ธ๐ซ' |
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
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
Empty file.
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
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
p3: main์ ๋จธ์ง๋ ๋๋ง cd ์ ์ฉ์ํค๋์?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
main์ pr์ฌ๋ผ์ฌ๋๋ ์์ฑ๋ฉ๋๋ค! main์ pr์ฌ๋ ค์ qa์งํํ๊ณ ๋ณ๊ฒฝํด์ผํ ์ฌํญ์์ผ๋ฉด pr ํด๋ก์ฆํ๊ณ ๋ค์ ์ฌ๋ฆฌ๋ ๋ฐฉ์์ ์๊ฐํ์์ต๋๋ค!
develop์ ์ ํฌ ํ์ธ์ฉ์ผ๋ก apk๊ฐ ๋งค pr๋ง๋ค ํ์ํ ์ง ๊ณ ๋ฏผํด๋ณด๋ฉด ์ข์ ๊ฒ ๊ฐ์์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๊ทธ ๋ฐฉ์์ด๋ฉด ์ ์ข์ต๋๋ค!