mammothestate
mammothestate

Reputation: 57

React Native - How to generate an APK from EAS that doesn't require a seperate development server

Running npx eas-cli build creates an APK that I installed on my phone. I do, however, need to start the server from my computer. I would like to have a working APK, that doesn't need this local server. I modified my EAS slightly according to docs. Though, unsure if I did right.

My eas.json:

{
"cli": {
    "version": ">= 3.3.2"
},
"build": {
    "development": {
        "distribution": "internal",
        "android": {
            "gradleCommand": ":app:assembleDebug"
        },
        "ios": {
            "buildConfiguration": "Debug"
        }
    },
    "preview": {
        "distribution": "internal",
        "android": {
            "buildType": "apk"
        }
    },
    "preview3": {
        "developmentClient": true
    },
    "production": {}
},
"submit": {
    "production": {}
}
}

I appreciate any help!

Upvotes: 0

Views: 1337

Answers (1)

eas build --profile preview --local 

--profile preview - gets config from your eas file. You've set "buildType": "apk" there.

--local - means that you'll use your machine for building an app.

Upvotes: 3

Related Questions