expo / expo/expo-github-action

'EAS build' fails via github action. Succeeds via local terminal.

Open
#283 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1k
Forks
107
PR merge metrics
No merged PRs in 30d

Description

### Description of the bug
'EAS build' fails when run via github action.
'EAS build' succeeds when run via local terminal.

### To Reproduce
What steps did you perform which led to this issue?

1. Set up GitHub Action with this yml, which I've named 'eas-build-on-push.yml':
```
name: EAS Build on Push to Main

on:
push:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: 🏗 Setup repo
uses: actions/checkout@v3

- name: Log working directory after checkout
run: pwd

- name: 🏗 Setup Node
uses: actions/setup-node@v3
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: client/package-lock.json

- name: Log working directory after setup Node
run: pwd

- name: 🏗 Setup EAS
uses: expo/expo-github-action@v8
with:
eas-version: latest
token: ${{ secrets.EXPO_TOKEN }}

- name: 📦 Install dependencies
run: npm install
working-directory: client

- name: Log working directory after install dependencies
run: pwd
working-directory: client

- name: 🚀 Build app
run: eas build -p android -e test
working-directory: client

- name: Log working directory after build
run: pwd
working-directory: client

```
2. Push from my local computer
3. EAS build starts
4. EAS build fails. Here is an extract of the output from expo.dev builds:
![image](https://github.com/expo/expo-github-action/assets/152653333/5efac8b0-dfa7-4f62-84be-349693b685f9)

#### Expected behavior
EAS build is successful.
If I execute eas build from my local terminal on the same commit, the build is successful.

#### Actual behavior
Build is not successful.

### Additional context
I suspect the issue may relate to my folder structure.

Relevant folders from my root are:
.github/workflows
.git/
/client/
/server/

Package-lock.json is here:
/client/package-lock.json

Working directory logs from expo (screenshot is from github action executing eas build):
![image](https://github.com/expo/expo-github-action/assets/152653333/87422020-1d20-4c24-b621-6aae46a3b749)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.