-
Notifications
You must be signed in to change notification settings - Fork 96
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: Use mobilestack references in android builds #6039
Conversation
@@ -39,8 +39,8 @@ jobs: | |||
with: | |||
secrets: |- | |||
ANDROID_RELEASE_KEYSTORE:projects/1027349420744/secrets/ANDROID_RELEASE_KEYSTORE | |||
CELO_RELEASE_KEY_PASSWORD:projects/1027349420744/secrets/CELO_RELEASE_KEY_PASSWORD | |||
CELO_RELEASE_STORE_PASSWORD:projects/1027349420744/secrets/CELO_RELEASE_STORE_PASSWORD | |||
MOBILESTACK_RELEASE_KEY_PASSWORD:projects/1027349420744/secrets/MOBILESTACK_RELEASE_KEY_PASSWORD |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've ported over these secrets in GCP
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6039 +/- ##
==========================================
- Coverage 88.93% 88.92% -0.01%
==========================================
Files 737 737
Lines 31371 31371
Branches 5800 5800
==========================================
- Hits 27899 27898 -1
- Misses 3274 3429 +155
+ Partials 198 44 -154 see 66 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
.github/workflows/e2e-android.yml
Outdated
@@ -50,6 +50,9 @@ jobs: | |||
yes | sdkmanager "platform-tools" "platforms;android-${{ inputs.android-api-level }}" | |||
set -o pipefail | |||
|
|||
# Install Ninja |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See here; not sure why this is now needed, though I have to imagine it's related to the rest of the changes in this PR
This seems to fail on the nightly release that I tested due to the build looking for celo-release-key.keystore, despite having removed all apparent references of it from the repo... not sure why this is happening. |
…allet into jophish/android-mobilestack
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!!
Oh wait, I just saw your comment about the release not working with these changes 🙈
The nightly release test passed! https://valora-app.slack.com/archives/C02D08P412Q/p1727385960907899 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀 LGTM! remember to populate the PR description before merging :D
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great!
android/gradle.properties
Outdated
# Note that the key alias lacks Mobile Stack naming, since updating this would | ||
# require regenerating the keystore. | ||
MOBILESTACK_RELEASE_STORE_FILE=mobilestack-release-key.keystore | ||
MOBILESTACK_RELEASE_KEY_ALIAS=celo-key-alias |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can update the keystore. Also an opportunity to use the same password for the store and the key inside.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jeanregisser What's the typical process for this? I assume we want to re-use our existing upload key; I can't seem to find an option in Android Studio (which is what I've used in the past for creating brand new upload keys/keystores) to create a new keystore from an existing key.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, this can be done using the keytool
cli:
- Renaming the alias: https://stackoverflow.com/a/5707518/158525
- Changing the passwords: https://stackoverflow.com/a/56382758/158525
android/app/src/androidTest/java/xyz/mobilestack/mobile/DetoxTest.java
Outdated
Show resolved
Hide resolved
The android release has been successfully tested here using a newly generated keystore with a different alias for the upload key as well as identical passwords for the store and private key. |
android/.project
Outdated
@@ -1,7 +1,7 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> | |||
<projectDescription> | |||
<name>celo</name> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure how much this name matters, but should we have the name here and in app/.project
consistent?
@@ -1,6 +1,6 @@ | |||
<?xml version="1.0" encoding="utf-8"?> | |||
<resources> | |||
<string name="persona_inquiry_start_title">Valora would like to verify your identity</string> | |||
<string name="persona_inquiry_start_title">This app would like to verify your identity</string> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wonder if this can somehow use app name. I guess its a barely used feature so maybe not too important
### Description Makes the Android builds more brand agnostic. Replaces the existing keystore android keystore containing the upload key by: * Renaming the private key alias within the keystore from `celo-release-key` to `mobilestack-release-key` * Using the same password for both the store as well as the private key within ### Test plan <!-- Demonstrate the change is solid, or why it doesn't need testing. Example: add any manual testing steps or scenarios (if not obvious), screenshots / videos if the pull request changes the user interface. --> ### Related issues - Fixes #[issue number here] ### Backwards compatibility <!-- Brief explanation of why these changes are/are not backwards compatible. --> ### Network scalability If a new NetworkId and/or Network are added in the future, the changes in this PR will: - [ ] Continue to work without code changes, OR trigger a compilation error (guaranteeing we find it when a new network is added)
Description
Makes the Android builds more brand agnostic. Replaces the existing keystore android keystore containing the upload key by:
celo-release-key
tomobilestack-release-key
Test plan
Related issues
Backwards compatibility
Network scalability
If a new NetworkId and/or Network are added in the future, the changes in this PR will: