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

Environment variables: Add ImageOS companion to ImageVersion #345

Closed
MSP-Greg opened this issue Feb 1, 2020 · 3 comments
Closed

Environment variables: Add ImageOS companion to ImageVersion #345

MSP-Greg opened this issue Feb 1, 2020 · 3 comments

Comments

@MSP-Greg
Copy link
Contributor

MSP-Greg commented Feb 1, 2020

This request is suggested as a means of simplifying the inputs needed to some actions.

In https://github.com/actions/virtual-environments/tags, new images are tagged as below:

win16/20200120.1
ubuntu18/20200119.1

ImageVersion is the second part of the tag. Having the first part of the tag ('OS String') set to an environment variable ImageOS would be helpful. As to macOS, maybe just that?

One use is building separate packages/binaries for use on all platforms. Obviously, one can use 'runs-on:' or '${{ matrix.os }}' as an action input, but having the image name as an env variable would be simpler...

Note: submitted to 'GitHub Community Forums', which was then closed with the suggestion to post to Feedback form for GitHub Actions, which I did. I thought an issue might result in feedback/discussion...

@al-cheb
Copy link
Contributor

al-cheb commented Feb 3, 2020

Hello, @MSP-Greg

To double check am i right it should be?

Name ImageOS ImageVersion
Windows 2016 win16 20200120.1
Windows Server 2019 win19 20200120.1
Ubuntu 16.04 ubuntu16 20200120.1
Ubuntu 18.04 ubuntu18 20200120.1
macOS Catalina 10.15 macOS 20200120.1

@MSP-Greg
Copy link
Contributor Author

MSP-Greg commented Feb 3, 2020

@al-cheb

Thanks.

Yes, that is what I intended.

Not sure about whether macOS needs any numeric suffix. If so, maybe macOS10.15 or macOS1015 ?

@al-cheb
Copy link
Contributor

al-cheb commented Mar 9, 2020

Hello, @MSP-Greg
We have added ImageOS for all GitHub images. Thank you for your help to provide new improvements.

@al-cheb al-cheb closed this as completed Mar 9, 2020
@miketimofeev miketimofeev removed the awaiting-deployment Code complete; awaiting deployment and/or deployment in progress label Mar 9, 2020
bryannaegele added a commit to bryannaegele/act that referenced this issue Jul 25, 2021
The current algorithm given `ubuntu-18.04` returns `ubuntu18.04` when it should be `ubuntu18` according to actions/runner-images#345 (comment).
mergify bot added a commit to nektos/act that referenced this issue Aug 1, 2021
The current algorithm given `ubuntu-18.04` returns `ubuntu18.04` when it should be `ubuntu18` according to actions/runner-images#345 (comment).

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
bravo-kernel added a commit to bravo-kernel/Actions that referenced this issue May 26, 2022
Changing the order of unique cache key generation to use `ImageOS` first so that matrix builds with e.g. multiple Linux versions do not break with below error message:

```
Unable to reserve cache with key Linux-psmodules-317DB88EFAFF4D1D0B5F92BF073201DA3F4083D92F59F60940FB05FABF623E14, another job may be creating this cache.
```

Reason:
- action currently generates a cache using "Linux" as the unique identifier
- this can sometimes lead to above error [as can be seen here](https://github.com/alt3/Docusaurus.Powershell/actions/runs/2389833954) (with two ubuntus using the same `Linux` cache key)
- using ImageOS should fix this as it would use e.g. `ubuntu16` and `ubuntu18`, [as explained here](actions/runner-images#345)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants