Skip to content

[FEAT/#226]Git Action CI/CD를 구축합니다.#241

Closed
MoonsuKang wants to merge 7 commits intodevelopfrom
feat/#226-gitaction-ci-cd
Closed

[FEAT/#226]Git Action CI/CD를 구축합니다.#241
MoonsuKang wants to merge 7 commits intodevelopfrom
feat/#226-gitaction-ci-cd

Conversation

@MoonsuKang
Copy link
Contributor

@MoonsuKang MoonsuKang commented Mar 30, 2025

📌 ISSUE

closed #226

📄 Work Description

  • CI/CD yml 추가
  • Firebase App Distribution 설정 추가
  • github secret 설정
  • staging 브랜치에 pr 시 discord web hook을 통해 알림 전송

✨ PR Point

📸 ScreenShot/Video

Summary by CodeRabbit

  • New Features
    • Introduced automated pipelines that streamline build, testing, and deployment processes.
    • Now enables rapid, secure distribution of pre-release app builds to testers along with real-time notifications.

@MoonsuKang MoonsuKang added ✨ FEAT 기능 개발 🌊 문수 문수 labels Mar 30, 2025
@MoonsuKang MoonsuKang requested a review from SYAAINN March 30, 2025 09:00
@MoonsuKang MoonsuKang self-assigned this Mar 30, 2025
@coderabbitai
Copy link

coderabbitai bot commented Mar 30, 2025

Important

Review skipped

More than 25% of the files skipped due to max files limit. The review is being skipped to prevent a low-quality review.

67 files out of 177 files are above the max files limit of 100. Please upgrade to Pro plan to get higher limits.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Walkthrough

This pull request introduces two new GitHub Actions workflows—one for continuous deployment (triggered on pull requests to the staging branch) and one for continuous integration (triggered on pull requests to the develop branch). Both workflows handle tasks such as code checkout, dependency caching, environment setup (JDK and Android SDK), and Firebase configuration by decoding secrets. In addition, the build scripts (Gradle files and version catalog) are updated to include the Firebase App Distribution plugin.

Changes

File(s) Change Summary
.github/workflows/android_cd.yml, .github/workflows/android_ci.yml Added two new GitHub Actions workflows for Android deployment and integration. The CD workflow builds a release AAB, deploys via Firebase App Distribution, and sends a Discord notification, while the CI workflow runs lint checks, code style verifications, and builds a debug APK.
app/build.gradle.kts, build.gradle.kts Integrated the Firebase App Distribution plugin into both Gradle build files. The app module applies the plugin, and the root build file includes it with apply false, allowing modular usage.
gradle/libs.versions.toml Added the firebase-app-distribution dependency with version 5.1.0 and created a corresponding library entry, enabling support for distributing pre-release versions through Firebase App Distribution.

Sequence Diagram(s)

sequenceDiagram
    participant PR as "PR (staging)"
    participant GitHub as "GitHub Actions"
    participant Build as "Build Environment"
    participant Firebase as "Firebase App Distribution"
    participant Discord as "Discord Webhook"
    
    PR->>GitHub: Trigger CD workflow on staging PR
    GitHub->>Build: Checkout code, cache deps, setup JDK/SDK
    Build->>GitHub: Build release AAB
    GitHub->>Firebase: Upload AAB for distribution
    Firebase-->>GitHub: Distribution confirmation
    GitHub->>Discord: Send notification about deployment
Loading
sequenceDiagram
    participant PR as "PR (develop)"
    participant GitHub as "GitHub Actions"
    participant Build as "Build Environment"
    participant Lint as "Code Quality Tools"
    
    PR->>GitHub: Trigger CI workflow on develop PR
    GitHub->>Build: Checkout code, cache deps, setup JDK/SDK
    Build->>Lint: Run ktlint & lint checks
    Lint-->>Build: Report issues or confirmation
    Build-->>GitHub: Assemble debug APK and finalize build
Loading

Assessment against linked issues

Objective Addressed Explanation
GitHub Actions CI/CD workflow setup (#226)
Firebase App Distribution configuration (#226)
GitHub secrets handling for secure configuration (#226)
Discord webhook integration for deployment notifications (#226)

Poem

I'm a rabbit with a bounce in my stride,
Crafting workflows with plenty of pride.
CI/CD paths now run smooth and neat,
Firebase and Discord join in the beat.
Through code and secrets the changes gleam,
Hopping forward in a continuous dream!
🐰🚀


🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai plan to trigger planning for file edits and PR creation.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a087607 and d1f582a.

📒 Files selected for processing (5)
  • .github/workflows/android_cd.yml (1 hunks)
  • .github/workflows/android_ci.yml (1 hunks)
  • app/build.gradle.kts (1 hunks)
  • build.gradle.kts (1 hunks)
  • gradle/libs.versions.toml (2 hunks)
🧰 Additional context used
🪛 actionlint (1.7.4)
.github/workflows/android_ci.yml

25-25: the runner of "actions/cache@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue

(action)


36-36: the runner of "actions/cache@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue

(action)

🔇 Additional comments (7)
build.gradle.kts (1)

10-13: Firebase App Distribution Plugin Integration

The addition of alias(libs.plugins.firebase.app.distribution) apply false in the plugins block properly introduces the Firebase App Distribution plugin at the project level without immediately applying it. This is a good practice in multi-module projects. Ensure that the corresponding Firebase credentials and configuration are set up correctly in the app module.

app/build.gradle.kts (1)

15-18: Enable Firebase App Distribution in the App Module

Adding alias(libs.plugins.firebase.app.distribution) into the app module’s plugins block integrates Firebase App Distribution into the build configuration. This enables the app to leverage Firebase’s distribution features. Please verify that the Firebase configuration (e.g., google-services.json) and secret keys are correctly provided in your CI/CD pipeline.

gradle/libs.versions.toml (1)

39-41: Addition of Firebase App Distribution Dependency

The new version entry for firebase-app-distribution = "5.1.0" (and its corresponding library declaration) properly establishes the version of the Firebase App Distribution plugin to be used. Ensure compatibility with your other Firebase dependencies and that this version meets your project’s requirements.

.github/workflows/android_ci.yml (1)

1-22: Overall CI Workflow Structure

The CI workflow is well-structured with appropriate steps such as code checkout, JDK and Android SDK setup, and code style checks. Please ensure that all the secrets (e.g., FIREBASE_SECRET, API keys) are correctly configured in the repository secrets to avoid runtime issues.

.github/workflows/android_cd.yml (3)

1-12: Continuous Deployment Workflow Initialization

The new continuous deployment workflow (android_cd.yml) is correctly triggered on pull requests to the staging branch. The overall structure—including steps for code checkout, dependency caching, JDK/Android SDK setup, and permission adjustments—appears robust.


66-68: Release Build Command Verification

The step that builds the release AAB (./gradlew bundleRelease --stacktrace) is correctly implemented. Ensure that the generated AAB path (app/build/outputs/bundle/release/app-release.aab) remains current with any future changes to the build configuration.


77-86: Firebase App Distribution and Discord Notification

The deployment steps for uploading the AAB to Firebase App Distribution and sending a notification to Discord are well implemented. Double-check that the Firebase App ID and Discord webhook URL are properly set in your GitHub secrets.

@MoonsuKang MoonsuKang closed this Mar 30, 2025
@MoonsuKang MoonsuKang deleted the feat/#226-gitaction-ci-cd branch March 30, 2025 09:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

✨ FEAT 기능 개발 🌊 문수 문수

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] Git Action CI/CD를 구축합니다.

1 participant