Skip to content
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

Setup fails on GitHub Actions using Ubuntu #50

Open
edaemon opened this issue Aug 2, 2024 · 9 comments
Open

Setup fails on GitHub Actions using Ubuntu #50

edaemon opened this issue Aug 2, 2024 · 9 comments

Comments

@edaemon
Copy link

edaemon commented Aug 2, 2024

A GitHub Actions workflow that was previously working now fails due to missing dependencies. The application is a regular Drupal site using the drupal10 recipe. The Actions workflow doesn't take any action related to Lando until it's invoked with:

      - name: Install Lando
        uses: lando/setup-lando@v3

This fails after 5 seconds or so and displays this:

image

This setup started failing intermittently yesterday, August 1, but now fails on every run. I've tested this with Ubuntu 20.04, 22.04 (ubuntu-latest), and 24.04 and gotten the same result. The failure seems especially odd because the output indicates that lando setup may fix the issue even though that's supposed to run automatically, but that error message doesn't indicate which dependency is missing.

Since this package hasn't changed in a while could this be related to changes made in the Actions runner images? It doesn't seem likely to be this specifically but they recently removed Docker Compose v1. Is there anything we can do to compensate or work around the problem?

@vml-bsummers
Copy link

I am seeing similar errors

@AaronFeledy
Copy link
Member

In the failed actions run, click the "re-run" button and enable the debug option. That should give more info about what is actually failing.

@reynoldsalec
Copy link
Member

Note that, in the cases where I was seeing failures due to the removal of Docker Compose from the GitHub Actions runners, making sure that setup-lando@v3 was being used, not v2, was the crux of the problem (thanks @AaronFeledy for identifying that).

@thomaslhotta
Copy link

I am having the same issue. Moving from setup-lando@v2 to v3 did not help.

Looking at the code, it seems to me like the lando version command failing:


Error: Command failed: /home/runner/work/_temp/18de01c4-ebc3-4d0c-8f6b-95f037c18085 version

  __  __  _  __           __  ____    __            __
 / / / / / |/ /__ ___ ___/ / / __/__ / /___ _____  / /
/ /_/ / /    / -_) -_) _  / _\ \/ -_) __/ // / _ \/_/ 
\____/ /_/|_/\__/\__/\_,_/ /___/\__/\__/\_,_/ .__(_)  
                                           /_/        

Lando has detected that it does not have all the dependencies it needs to run.
But FEAR NOT because we have a special hidden convenience command called lando setup
which will do the heavy lifting and set you right.

...


I fixed the issue in the meantime by installing docker compose before running setup-lando using KengoTODA/actions-setup-docker-compose

@reynoldsalec
Copy link
Member

The error I've seen withlando version I believe is a regression where the command will bootstrap a .lando.yml if it exists in the project's root. For all our Lando plugins, this creates an error since we use the "dev-slim" release of Lando, and the Lando plugins use a type: node service that won't be available in the slim Lando releases.

Until that is fixed, one option is to specify the stable release of Lando (instead of using a dev release) in the setup-lando GHA options.

@tpluscode
Copy link

Thank you @thomaslhotta for the workaround.

Is there any ETA @reynoldsalec ?

@reynoldsalec
Copy link
Member

@tpluscode I think the issue I was bringing up (lando version running on the .lando.yml files in the root of our plugins and not having access to the node service because GHA is setup with the "slim" version of Lando and thus doesn't have node) is actually unrelated to the issue as I understand it from @edaemon and @thomaslhotta description; I would disregard my comment.

If you're getting a "U Need Setup" message, that was a problem with an autosetup introduced in 3.22.0-beta.1. That issue is resolved in 3.22.0-beta.5, so it should be resolved if you're running an edge release of Lando.

If anyone is still having problems here, let me know your specific error and paste me a copy of your setup-lando invocation so I can see the options.

@finau
Copy link

finau commented Oct 2, 2024

My pipeline is broken and I just found out the error is lando UNeedSetup. I didn't get that error before, just found out today.
Screenshot 2024-10-03 at 2 41 10 AM (3)
Screenshot 2024-10-03 at 2 48 18 AM (3)

@reynoldsalec - any recommendation on how can I fix this problem pls.

@reynoldsalec
Copy link
Member

reynoldsalec commented Oct 2, 2024

@finau I'd recommend using the setup-lando action that belongs to this repo, it'll run through the appropriate steps to download Docker Compose for you. If you don't want to implement that, I suspect since you're running a 3.21 version of Lando you could simply install Docker Compose prior to running your "Grab latest Lando CLI" step (see #50 (comment)).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants