question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

v0.26.0 moving eas submit options to the app.json file is incompatible with gitlab ci

See original GitHub issue

Summary

Changes in v0.26.0 to move the params out of the cli command and into the eas.json submit profile are incompatible with referencing the google service account path as an environment variable in Gitlab CI.

Pre v26

eas submit --platform android --latest --key=$GOOGLE_SERVICE_ACCOUNT

Post v26

eas submit --platform android --latest --profile ci

eas.json:

...
"ci": {
      "android": {
        "track": "alpha",
        "serviceAccountKeyPath": "$GOOGLE_SERVICE_ACCOUNT" 
      },
...

The changes in release v0.26.0 moved things like the --key param into the submit profile, so I added $GOOGLE_SERVICE_ACCOUNT as the value in there, however, this doesn’t seem to successfully reference the gitlab CI environment variable, it instead treats it as just a string.

Has anyone else come across this yet since the v0.26.0 update? For obvious reasons I can’t simply commit the google service account to the repo and hardcode the path in the eas.json. Am I doing something wrong or is this change simply incompatible?

Environment

EAS CLI 0.26.0 environment info:
    System:
      OS: Linux 5.4 Debian GNU/Linux 9 (stretch) 9 (stretch)
      Shell: 4.4.12 - /bin/bash
    Binaries:
      Node: 12.22.6 - /usr/local/bin/node
      Yarn: 1.22.5 - /usr/local/bin/yarn
      npm: 6.14.15 - /usr/local/bin/npm
    Utilities:
      Git: 2.11.0 - /usr/bin/git
    npmPackages:
      expo: ^42.0.0 => 42.0.3 
      react: 16.13.1 => 16.13.1 
      react-dom: 16.13.1 => 16.13.1 
      react-native: https://github.com/expo/react-native/archive/sdk-42.0.0.tar.gz => 0.63.2 
      react-native-web: ~0.13.12 => 0.13.18 

Error output

File $GOOGLE_SERVICE_ACCOUNT doesn't exist.
A Google Service Account JSON key is required to upload your app to Google Play Store.
If you're not sure what this is or how to create one, Learn more: https://expo.fyi/creating-google-service-account
    Error: Input is required, but stdin is not readable.
error Command failed with exit code 1.

Reproducible demo or steps to reproduce from a blank project

Use gitlab ci referencing the google service account key path in the eas.json submit profile as a gitlab ci variable

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
DominikIlskicommented, Sep 9, 2021

Same issue here

1reaction
dsokalcommented, Sep 10, 2021

Ok, fair enough. I didn’t know Gitlab lets you mark an env variable as a file. I’ll implement the support for this soon 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Configuring EAS Submit with eas.json - Expo Documentation
eas.json is your go-to place for configuring EAS Submit (and EAS Build). It is located at the root of your project next to...
Read more >
eas build --local doesn't work with google services files #1253
When launching a build in a CI environment (or on a local machine, tested with macOS) with eas build --local and a package...
Read more >
JSON formatting with jq and CI/CD linting automation | GitLab
Learn how to filter in JSON data structures and interact with the REST API. Use the GitLab API to lint your CI/CD configuration...
Read more >
Mattermost legacy self-hosted changelog
Mattermost is an open source platform for secure collaboration across the entire software development lifecycle. This changelog summarizes updates for all ...
Read more >
Changelog — foremast 5.15.4.dev1 documentation
Friendly error when env is not defined in pipeline json files. [linjmeyer] ... Moved tagging, versioning and logging to master bucket settings.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found