diff options
| author | Albin <albin@mullvad.net> | 2022-12-02 13:06:39 +0100 |
|---|---|---|
| committer | Albin <albin@mullvad.net> | 2022-12-08 14:46:35 +0100 |
| commit | d3a46886fde75500f62f68bca69e83347071c334 (patch) | |
| tree | f4d311e2fd226fc7e30182aebda0cbb3548220bf | |
| parent | 0e5c1badb7e8672aa955ed59b6ebe606a5975865 (diff) | |
| download | mullvadvpn-d3a46886fde75500f62f68bca69e83347071c334.tar.xz mullvadvpn-d3a46886fde75500f62f68bca69e83347071c334.zip | |
Change Android signing keystore path
Changes the keystore and keystore property file path to make it easier
to use for containerized builds, especially in terms of mounting.
New path: android/app/credentials/{app-keys.jks,keystore.properties}
As the storeFile property is relative to the app build gradle files
it's now set by the gradle script rather than reading the property.
| -rw-r--r-- | android/app/build.gradle.kts | 7 | ||||
| -rwxr-xr-x | build-apk.sh | 2 |
2 files changed, 5 insertions, 4 deletions
diff --git a/android/app/build.gradle.kts b/android/app/build.gradle.kts index 95c9cba0a6..e61156ca13 100644 --- a/android/app/build.gradle.kts +++ b/android/app/build.gradle.kts @@ -16,7 +16,8 @@ val extraAssetsDirectory = "${project.buildDir}/extraAssets" val defaultChangeLogAssetsDirectory = "$repoRootPath/android/src/main/play/release-notes/" val extraJniDirectory = "${project.buildDir}/extraJni" -val keystorePropertiesFile = file("${rootProject.projectDir}/keystore.properties") +val credentialsPath = "${rootProject.projectDir}/credentials" +val keystorePropertiesFile = file("$credentialsPath/keystore.properties") val keystoreProperties = Properties() if (keystorePropertiesFile.exists()) { @@ -46,10 +47,10 @@ android { if (keystorePropertiesFile.exists()) { signingConfigs { create("release") { + storeFile = file("$credentialsPath/app-keys.jks") + storePassword = keystoreProperties.getProperty("storePassword") keyAlias = keystoreProperties.getProperty("keyAlias") keyPassword = keystoreProperties.getProperty("keyPassword") - storeFile = file(keystoreProperties.getProperty("storeFile")) - storePassword = keystoreProperties.getProperty("storePassword") } } diff --git a/build-apk.sh b/build-apk.sh index f3484e677b..c781bd7fb0 100755 --- a/build-apk.sh +++ b/build-apk.sh @@ -50,7 +50,7 @@ while [ ! -z "${1:-""}" ]; do done if [[ "$GRADLE_BUILD_TYPE" == "release" ]]; then - if [ ! -f "$SCRIPT_DIR/android/keystore.properties" ]; then + if [ ! -f "$SCRIPT_DIR/android/credentials/keystore.properties" ]; then echo "ERROR: No keystore.properties file found" >&2 echo " Please configure the signing keys as described in the README" >&2 exit 1 |
