Skip to content

CI/CD Pipeline Setup for ChaimRemit Mobile App #1

Description

@Pvsaint

Description

Set up a comprehensive CI/CD pipeline for the ChaimRemit React Native mobile application to automate testing, building, and deployment processes for both iOS and Android platforms.

High - Essential for development workflow and production deployment

Acceptance Criteria

GitHub Actions Workflow

  • Create .github/workflows/mobile-ci.yml for continuous integration
  • Create .github/workflows/mobile-cd.yml for continuous deployment
  • Set up automated testing on pull requests
  • Configure build matrix for iOS and Android
  • Implement caching for node_modules and build artifacts

Testing Pipeline

  • Run ESLint and TypeScript checks
  • Execute Jest unit tests with coverage reporting
  • Run Detox E2E tests on simulators/emulators
  • Generate and upload test coverage reports
  • Fail pipeline if tests don't meet coverage threshold (80%)

Build Pipeline

  • Configure Android APK/AAB builds
  • Configure iOS IPA builds (requires macOS runner)
  • Set up code signing for both platforms
  • Generate build artifacts and upload to GitHub releases
  • Create separate builds for development, staging, and production

Deployment Pipeline

  • Automatic deployment to internal testing (TestFlight/Internal Testing)
  • Manual approval gate for production deployment
  • Deploy to App Store Connect and Google Play Console
  • Send Slack/Discord notifications on deployment status
  • Rollback mechanism for failed deployments

Technical Requirements

Environment Setup

```yaml

Required GitHub Secrets

ANDROID_KEYSTORE_BASE64
ANDROID_KEYSTORE_PASSWORD
ANDROID_KEY_ALIAS
ANDROID_KEY_PASSWORD
IOS_CERTIFICATE_BASE64
IOS_PROVISIONING_PROFILE_BASE64
IOS_CERTIFICATE_PASSWORD
APP_STORE_CONNECT_API_KEY
GOOGLE_PLAY_SERVICE_ACCOUNT_JSON
SLACK_WEBHOOK_URL (optional)
```

Build Configuration

  • Node.js version: 18.x
  • React Native CLI version: Latest stable
  • Xcode version: 14.x (for iOS builds)
  • Android SDK: API level 33
  • Java version: 11

Workflow Triggers

  • Pull requests to main and develop branches
  • Push to main branch (for deployment)
  • Manual workflow dispatch for emergency builds
  • Scheduled nightly builds for development branch

Implementation Details

CI Workflow Structure

```yaml
name: Mobile CI
on:
pull_request:
branches: [main, develop]
paths: ['mobile/']
push:
branches: [main, develop]
paths: ['mobile/
']

jobs:
lint-and-test:
runs-on: ubuntu-latest
steps:
- Checkout code
- Setup Node.js
- Cache dependencies
- Install dependencies
- Run linting
- Run unit tests
- Upload coverage

build-android:
runs-on: ubuntu-latest
needs: lint-and-test
steps:
- Build Android APK/AAB
- Sign Android build
- Upload artifacts

build-ios:
runs-on: macos-latest
needs: lint-and-test
steps:
- Build iOS IPA
- Sign iOS build
- Upload artifacts

e2e-tests:
runs-on: macos-latest
needs: [build-android, build-ios]
steps:
- Run Detox tests on iOS simulator
- Run Detox tests on Android emulator
```

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions