I am currently trying to build a standalone app with the assets bundled through turtle-cli. The apk that is produced does have the assets bundled as I can see them when viewing the apk in android studio. But when I install the app and open on an android phone, I get the error message: Error: Failed to connect to localhost/127.0.0.1:4443 and my images are not showing.
Expo version: 36.0.2
Expo cli version: 3.21.5
Turtle cli version: 0.15.0
Below is the publish/build process:
expo export --public-url https://localhost:4443 --no-dev
cd dist
python $(httpsServer.secureFilePath) $(serverCert.SecureFilePath) &
cd ..
turtle setup:android
EXPO_ANDROID_KEYSTORE_PASSWORD=$(EXPO_ANDROID_KEYSTORE_PASSWORD)
EXPO_ANDROID_KEY_PASSWORD=$(EXPO_ANDROID_KEY_PASSWORD)
turtle build:android --keystore-path $(keyStore.secureFilePath) --keystore-alias $(keystore-alias) -t
apk --public-url https://localhost:4443/android-index.json
My app.json includes this:
"updates": {
"enabled": false
},
"assetBundlePatterns": [
"assets/images/*"
],
I found a similar issue at SDK 32 Android Bundled Assets not loading - #11 by jamesmorad. I did change my export command from using -dev option to using the --no-dev option. This didn’t solve my issue and I also get a new error - error: unknown option `–no-dev’. Am I missing something?