Azure / static-web-apps-cli

Azure Static Web Apps CLI ✨
https://aka.ms/swa/cli-local-development
MIT License
583 stars 109 forks source link

ci: change macos-latest to macos-12 to keep supporting node 14 #828

Closed cjk7989 closed 1 month ago

cjk7989 commented 1 month ago

We’ve encountered a failure in our GitHub Actions workflow where the job that tests on the macOS runner is unable to find a compatible version of Node 14. This issue occurred 1 or 2 months ago.

This issue has arisen due to a recent update in GitHub Actions’ virtual environments, where macos-latest now points to macOS 14 (Sonoma) running on Apple’s M1 chip: Actions new ship 🚢 - macOS 14 (Sonoma) and the new M1 macOS runner · community · Discussion #102846 (github.com), while there is no NodeJs 14 that is built for ARM64: Using NodeJs 14 with Mac Silicon (M1) (devzilla.io).

To address this, this PR modified our CI pipeline configuration by changing the runs-on value from macos-latest to macos-12, which was the version labeled as "latest" before macos-14. This change ensures that our workflow uses the previous version of macOS, which supports Node 14 and is compatible with our current testing setup.

Considering macos-12 will eventually be deprecated, I recommend we update our Node versions or adjust our codebase for compatibility with newer macOS runners.