feat: EAS build config for Android APK + BUILD.md (FIBEROPS-210)

- Add versionCode: 1 to app.json android section
- Add preview-local build profile to eas.json (local Gradle build)
- Add build:android:apk and build:android:local npm scripts
- Add BUILD.md documenting EAS cloud and local build instructions
This commit is contained in:
2026-04-01 01:08:04 +00:00
parent c649b2f61b
commit bc22f0c6f6
4 changed files with 71 additions and 1 deletions

59
BUILD.md Normal file
View File

@@ -0,0 +1,59 @@
# Building FiberOps Android APK
## Requirements
- [Expo account](https://expo.dev) — register at expo.dev
- EAS CLI: `npm install -g eas-cli`
- Authenticate: `eas login`
## Build (EAS Cloud — recommended)
Builds the APK on Expo's cloud infrastructure. No local Android SDK needed.
```bash
eas build --profile preview --platform android
```
Or via npm script:
```bash
npm run build:android:apk
```
The build will be queued on EAS. Once complete, download the `.apk` from the Expo dashboard or the URL printed in the CLI output.
## Build (local — requires Android SDK)
Requires Android SDK installed and `ANDROID_HOME` set.
```bash
npm run build:android:local
# or directly:
eas build --local --profile preview --platform android
```
Alternatively, use the Expo CLI directly:
```bash
npx expo run:android --variant release
```
## Distribution
The `preview` profile is configured for **internal distribution** (`buildType: apk`). Share the `.apk` file directly with testers — no Play Store submission needed.
## Current status
- QA passed: MOB.1 (manual tasks), MOB.2 (remittance review)
- EAS project ID: `15d21320-57f5-4fb6-a116-82d222d914e2`
- Package: `com.fiberops.mobile`
- Version: `1.0.0` (versionCode: 1)
## EAS build profiles
| Profile | Distribution | Output | Use case |
|---------|-------------|--------|----------|
| `preview` | internal | APK (EAS cloud) | QA / internal testing |
| `preview-local` | internal | APK (local Gradle) | Offline / CI builds |
| `development` | internal | Dev client | Development |
| `production` | store | AAB | Play Store release |

View File

@@ -22,6 +22,7 @@
"backgroundColor": "#0891B2" "backgroundColor": "#0891B2"
}, },
"package": "com.fiberops.mobile", "package": "com.fiberops.mobile",
"versionCode": 1,
"permissions": [ "permissions": [
"android.permission.CAMERA", "android.permission.CAMERA",
"android.permission.RECORD_AUDIO", "android.permission.RECORD_AUDIO",

View File

@@ -13,6 +13,14 @@
"buildType": "apk" "buildType": "apk"
} }
}, },
"preview-local": {
"distribution": "internal",
"android": {
"buildType": "apk",
"gradleCommand": ":app:assembleRelease"
},
"env": {}
},
"production": { "production": {
"autoIncrement": true "autoIncrement": true
} }

View File

@@ -6,7 +6,9 @@
"start": "expo start", "start": "expo start",
"android": "expo start --android", "android": "expo start --android",
"ios": "expo start --ios", "ios": "expo start --ios",
"web": "expo start --web" "web": "expo start --web",
"build:android:apk": "eas build --profile preview --platform android --non-interactive",
"build:android:local": "eas build --local --profile preview --platform android"
}, },
"dependencies": { "dependencies": {
"@react-native-async-storage/async-storage": "2.2.0", "@react-native-async-storage/async-storage": "2.2.0",