shapehq / tartelet

⚙️💻 A macOS app that makes it a breeze to manage multiple GitHub Actions runners in ephemeral virtual machines on a single host machine. The benefits are that runners can run in parallel, and each job runs in an isolated environment.
MIT License
501 stars 15 forks source link

Ensures GitHub is available prior to downloading the runner #56

Closed simonbs closed 8 months ago

simonbs commented 8 months ago

The changes in this PR ensures that we do not attempt downloading the runner or setting up the runner until we have verified that the virtual machine is able to contact GitHub.

Failure to communicate with github.com, e.g. because the virtual machine did not have an Internet connection, would previously result in an error in the script, at which point the virtual machine would reboot. This could result in a boot loop if we were unable to communicate with github.com for a long period.

xavierLowmiller commented 5 months ago

Would you consider changing the test from a ping to something like curl -s https://github.com > /dev/null? Today, I ran into an issue where curl works fine on Github, but ping doesn't, so this might be a bad proxy for detecting availability.

It's also what reddit suggests for similar issues (in more profane words)

simonbs commented 5 months ago

@xavierLowmiller Sure! I didn't know about this issue. I won't have time to address it the next few days but I'm happy to review and merge a PR that fixes it 🙏

xavierLowmiller commented 5 months ago

Great! I'm happy to put one up :v: