diff --git a/appveyor.yml b/appveyor.yml index 49da3834c..ee0bd1c37 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -55,7 +55,7 @@ before_build: - ps: | if($isWindows) { nuget restore - if($env:KEYSTORE_DEC_SECRET -or $env:GOOGLE_SERVICES_DEC_SECRET -or $env:PLAY_DEC_SECRET) { + if($env:UPLOAD_KEYSTORE_DEC_SECRET -or$env:KEYSTORE_DEC_SECRET -or $env:GOOGLE_SERVICES_DEC_SECRET -or $env:PLAY_DEC_SECRET) { nuget install secure-file -ExcludeVersion } if($env:GOOGLE_SERVICES_DEC_SECRET) { diff --git a/src/Android/Android.csproj b/src/Android/Android.csproj index 89ef19db1..afe27f7a3 100644 --- a/src/Android/Android.csproj +++ b/src/Android/Android.csproj @@ -152,6 +152,7 @@ + diff --git a/src/Android/ci-build-apks.ps1 b/src/Android/ci-build-apks.ps1 index dbf191f0a..240330c07 100644 --- a/src/Android/ci-build-apks.ps1 +++ b/src/Android/ci-build-apks.ps1 @@ -22,18 +22,21 @@ echo "##### Decrypt Keystore" echo "########################################" $encKeystorePath = $($rootPath + "\src\Android\8bit.keystore.enc"); +$encUploadKeystorePath = $($rootPath + "\src\Android\upload-keystore.jks.enc"); $secureFilePath = $($rootPath + "\secure-file\tools\secure-file.exe"); Invoke-Expression "& `"$secureFilePath`" -decrypt $($encKeystorePath) -secret $($env:keystore_dec_secret)" +Invoke-Expression "& `"$secureFilePath`" -decrypt $($encUploadKeystorePath) -secret $($env:upload_keystore_dec_secret)" echo "########################################" echo "##### Sign Release Configuration" echo "########################################" msbuild "$($androidPath)" "/t:SignAndroidPackage" "/p:Configuration=Release" "/p:AndroidKeyStore=true" ` - "/p:AndroidSigningKeyAlias=bitwarden" "/p:AndroidSigningKeyPass=$($env:keystore_password)" ` - "/p:AndroidSigningKeyStore=8bit.keystore" "/p:AndroidSigningStorePass=$($env:keystore_password)" "/v:quiet" - + "/p:AndroidSigningKeyAlias=upload" "/p:AndroidSigningKeyPass=$($env:upload_keystore_password)" ` + "/p:AndroidSigningKeyStore=upload-keystore.jks.enc" "/p:AndroidSigningStorePass=$($env:upload_keystore_password)" ` + "/v:quiet" + echo "########################################" echo "##### Copy Release apk to project root" echo "########################################" diff --git a/src/Android/upload-keystore.jks.enc b/src/Android/upload-keystore.jks.enc new file mode 100644 index 000000000..bf413f8ea Binary files /dev/null and b/src/Android/upload-keystore.jks.enc differ