mirror of
https://github.com/actions/runner-images.git
synced 2025-12-10 11:07:02 +00:00
virtual-environments => runner-images (#6033)
* virtual-environments => runner-images - as per https://github.blog/changelog/2022-08-08-github-actions-runner-images-repository-refresh * revert readme changes - as per https://github.com/actions/runner-images/pull/6033#discussion_r941173809
This commit is contained in:
committed by
GitHub
parent
03b7305ca1
commit
4994130a96
4
.github/ISSUE_TEMPLATE/config.yml
vendored
4
.github/ISSUE_TEMPLATE/config.yml
vendored
@@ -2,5 +2,5 @@ blank_issues_enabled: false
|
|||||||
|
|
||||||
contact_links:
|
contact_links:
|
||||||
- name: Get help in GitHub Discussions
|
- name: Get help in GitHub Discussions
|
||||||
url: https://github.com/actions/virtual-environments/discussions
|
url: https://github.com/actions/runner-images/discussions
|
||||||
about: Have a question? Feel free to ask in the virtual-environments GitHub Discussions!
|
about: Have a question? Feel free to ask in the runner-images GitHub Discussions!
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
[fork]: https://github.com/actions/virtual-environments/fork
|
[fork]: https://github.com/actions/runner-images/fork
|
||||||
[pr]: https://github.com//actions/virtual-environments/compare
|
[pr]: https://github.com//actions/runner-images/compare
|
||||||
[code-of-conduct]: CODE_OF_CONDUCT.md
|
[code-of-conduct]: CODE_OF_CONDUCT.md
|
||||||
|
|
||||||
Hi there! We're thrilled that you'd like to contribute to this project. Your help is essential for keeping it great.
|
Hi there! We're thrilled that you'd like to contribute to this project. Your help is essential for keeping it great.
|
||||||
|
|||||||
26
README.md
26
README.md
@@ -34,14 +34,14 @@ To build a VM machine from this repo's source, see the [instructions](docs/creat
|
|||||||
- In general the `-latest` label is used for the latest OS image version that is GA
|
- In general the `-latest` label is used for the latest OS image version that is GA
|
||||||
- Before moving the`-latest` label to a new OS version we will announce the change and give sufficient lead time for users to update their workflows
|
- Before moving the`-latest` label to a new OS version we will announce the change and give sufficient lead time for users to update their workflows
|
||||||
|
|
||||||
[ubuntu-22.04]: https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2204-Readme.md
|
[ubuntu-22.04]: https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu2204-Readme.md
|
||||||
[ubuntu-20.04]: https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md
|
[ubuntu-20.04]: https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu2004-Readme.md
|
||||||
[ubuntu-18.04]: https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu1804-Readme.md
|
[ubuntu-18.04]: https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu1804-Readme.md
|
||||||
[windows-2022]: https://github.com/actions/virtual-environments/blob/main/images/win/Windows2022-Readme.md
|
[windows-2022]: https://github.com/actions/runner-images/blob/main/images/win/Windows2022-Readme.md
|
||||||
[windows-2019]: https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md
|
[windows-2019]: https://github.com/actions/runner-images/blob/main/images/win/Windows2019-Readme.md
|
||||||
[macOS-11]: https://github.com/actions/virtual-environments/blob/main/images/macos/macos-11-Readme.md
|
[macOS-11]: https://github.com/actions/runner-images/blob/main/images/macos/macos-11-Readme.md
|
||||||
[macOS-12]: https://github.com/actions/virtual-environments/blob/main/images/macos/macos-12-Readme.md
|
[macOS-12]: https://github.com/actions/runner-images/blob/main/images/macos/macos-12-Readme.md
|
||||||
[macOS-10.15]: https://github.com/actions/virtual-environments/blob/main/images/macos/macos-10.15-Readme.md
|
[macOS-10.15]: https://github.com/actions/runner-images/blob/main/images/macos/macos-10.15-Readme.md
|
||||||
[self-hosted runners]: https://help.github.com/en/actions/hosting-your-own-runners
|
[self-hosted runners]: https://help.github.com/en/actions/hosting-your-own-runners
|
||||||
|
|
||||||
## Image Definitions
|
## Image Definitions
|
||||||
@@ -69,14 +69,14 @@ latest 2 versions of an OS.
|
|||||||
|
|
||||||
*How to best follow along with changes*
|
*How to best follow along with changes*
|
||||||
|
|
||||||
1. Find the latest releases for this repository [here.](https://github.com/actions/virtual-environments/releases)
|
1. Find the latest releases for this repository [here.](https://github.com/actions/runner-images/releases)
|
||||||
2. Subscribe to the releases coming out of this repository, instructions [here.](https://docs.github.com/en/account-and-profile/managing-subscriptions-and-notifications-on-github/setting-up-notifications/configuring-notifications#configuring-your-watch-settings-for-an-individual-repository)
|
2. Subscribe to the releases coming out of this repository, instructions [here.](https://docs.github.com/en/account-and-profile/managing-subscriptions-and-notifications-on-github/setting-up-notifications/configuring-notifications#configuring-your-watch-settings-for-an-individual-repository)
|
||||||
3. Upcoming changes: A pre-release is created when the deployment of an image has started. As soon as the deployment is finished, the pre-release is converted to a release. If you have subscribed to releases, you will get notified of pre-releases as well.
|
3. Upcoming changes: A pre-release is created when the deployment of an image has started. As soon as the deployment is finished, the pre-release is converted to a release. If you have subscribed to releases, you will get notified of pre-releases as well.
|
||||||
|
|
||||||
- You can also track upcoming changes using the [awaiting-deployment](https://github.com/actions/virtual-environments/labels/awaiting-deployment) label.
|
- You can also track upcoming changes using the [awaiting-deployment](https://github.com/actions/runner-images/labels/awaiting-deployment) label.
|
||||||
4. For high impact changes, we will post these in advance to the GitHub Changelog on our [blog](https://github.blog/changelog/) and on [twitter](https://twitter.com/GHchangelog).
|
4. For high impact changes, we will post these in advance to the GitHub Changelog on our [blog](https://github.blog/changelog/) and on [twitter](https://twitter.com/GHchangelog).
|
||||||
- Ex: breaking changes, GA or deprecation of images
|
- Ex: breaking changes, GA or deprecation of images
|
||||||
5. You can also view notable upcoming changes by viewing the [Announcement](https://github.com/actions/virtual-environments/labels/Announcement) label.
|
5. You can also view notable upcoming changes by viewing the [Announcement](https://github.com/actions/runner-images/labels/Announcement) label.
|
||||||
|
|
||||||
*Cadence*
|
*Cadence*
|
||||||
|
|
||||||
@@ -131,8 +131,8 @@ In general, these are the guidelines we follow when deciding what to pre-install
|
|||||||
|
|
||||||
## How to Interact with the Repo
|
## How to Interact with the Repo
|
||||||
|
|
||||||
- **Issues**: To file a bug report, or request tools to be added/updated, please [open an issue using the appropriate template](https://github.com/actions/virtual-environments/issues/new/choose)
|
- **Issues**: To file a bug report, or request tools to be added/updated, please [open an issue using the appropriate template](https://github.com/actions/runner-images/issues/new/choose)
|
||||||
- **Discussions**: If you want to share your thoughts about image configuration, installed software, or bring a new idea, please create a new topic in a [discussion](https://github.com/actions/virtual-environments/discussions) for a corresponding category. Before making a new discussion please make sure no similar topics were created earlier.
|
- **Discussions**: If you want to share your thoughts about image configuration, installed software, or bring a new idea, please create a new topic in a [discussion](https://github.com/actions/runner-images/discussions) for a corresponding category. Before making a new discussion please make sure no similar topics were created earlier.
|
||||||
- For general questions about using the runner images or writing your Actions workflow, please open requests in the [GitHub Actions Community Forum](https://github.community/c/github-actions/41).
|
- For general questions about using the runner images or writing your Actions workflow, please open requests in the [GitHub Actions Community Forum](https://github.community/c/github-actions/41).
|
||||||
|
|
||||||
## FAQs
|
## FAQs
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
# Virtual-Environments
|
# Virtual-Environments
|
||||||
The virtual-environments project uses [Packer](https://www.packer.io/) to generate disk images for the following platforms: Windows 2019/2022, Ubuntu 18.04/20.04/22.04.
|
The runner-images project uses [Packer](https://www.packer.io/) to generate disk images for the following platforms: Windows 2019/2022, Ubuntu 18.04/20.04/22.04.
|
||||||
Each image is configured through a JSON template that Packer understands and which specifies where to build the image (Azure in this case), and what scripts to run to install software and prepare the disk.
|
Each image is configured through a JSON template that Packer understands and which specifies where to build the image (Azure in this case), and what scripts to run to install software and prepare the disk.
|
||||||
The Packer process initializes a connection to Azure subscription via Azure CLI, and automatically creates the temporary Azure resources required to build the source VM(temporary resource group, network interfaces, and VM from the "clean" image specified in the template).
|
The Packer process initializes a connection to Azure subscription via Azure CLI, and automatically creates the temporary Azure resources required to build the source VM(temporary resource group, network interfaces, and VM from the "clean" image specified in the template).
|
||||||
If the VM deployment succeeds, the build agent connects to the VM and starts to execute installation steps from the JSON template.
|
If the VM deployment succeeds, the build agent connects to the VM and starts to execute installation steps from the JSON template.
|
||||||
@@ -50,13 +50,13 @@ Invoke-WebRequest -Uri https://aka.ms/installazurecliwindows -OutFile .\AzureCLI
|
|||||||
Download Virtual-Environments repository.
|
Download Virtual-Environments repository.
|
||||||
```
|
```
|
||||||
Set-Location c:\
|
Set-Location c:\
|
||||||
git clone https://github.com/actions/virtual-environments.git
|
git clone https://github.com/actions/runner-images.git
|
||||||
```
|
```
|
||||||
|
|
||||||
Import [GenerateResourcesAndImage](../helpers/GenerateResourcesAndImage.ps1) script from `/helpers` folder, and run `GenerateResourcesAndImage` function via Powershell.
|
Import [GenerateResourcesAndImage](../helpers/GenerateResourcesAndImage.ps1) script from `/helpers` folder, and run `GenerateResourcesAndImage` function via Powershell.
|
||||||
|
|
||||||
```
|
```
|
||||||
Set-Location C:\virtual-environments
|
Set-Location C:\runner-images
|
||||||
|
|
||||||
Import-Module .\helpers\GenerateResourcesAndImage.ps1
|
Import-Module .\helpers\GenerateResourcesAndImage.ps1
|
||||||
|
|
||||||
@@ -89,7 +89,7 @@ GenerateResourcesAndImage -SubscriptionId {YourSubscriptionId} -ResourceGroupNam
|
|||||||
After the successful image generation, Virtual Machine can be created from the generated VHD using [CreateAzureVMFromPackerTemplate](../helpers/CreateAzureVMFromPackerTemplate.ps1) script.
|
After the successful image generation, Virtual Machine can be created from the generated VHD using [CreateAzureVMFromPackerTemplate](../helpers/CreateAzureVMFromPackerTemplate.ps1) script.
|
||||||
|
|
||||||
```
|
```
|
||||||
Set-Location C:\virtual-environments
|
Set-Location C:\runner-images
|
||||||
|
|
||||||
Import-Module .\helpers\CreateAzureVMFromPackerTemplate.ps1
|
Import-Module .\helpers\CreateAzureVMFromPackerTemplate.ps1
|
||||||
|
|
||||||
@@ -151,8 +151,8 @@ Generated tool versions and details can be found in related projects:
|
|||||||
> :warning: These scripts are intended to run on a VM deployed in Azure
|
> :warning: These scripts are intended to run on a VM deployed in Azure
|
||||||
|
|
||||||
The user, created during the image generation, does not exist in the result VHD hence some configuration files related to the user's home directory need to be changed as well as the file permissions for some directories. Scripts for that are located in the `post-generation` folder in the repository:
|
The user, created during the image generation, does not exist in the result VHD hence some configuration files related to the user's home directory need to be changed as well as the file permissions for some directories. Scripts for that are located in the `post-generation` folder in the repository:
|
||||||
- Windows: https://github.com/actions/virtual-environments/tree/main/images/win/post-generation
|
- Windows: https://github.com/actions/runner-images/tree/main/images/win/post-generation
|
||||||
- Linux: https://github.com/actions/virtual-environments/tree/main/images/linux/post-generation
|
- Linux: https://github.com/actions/runner-images/tree/main/images/linux/post-generation
|
||||||
|
|
||||||
**Note:** The default user for Linux should have `sudo privileges`.
|
**Note:** The default user for Linux should have `sudo privileges`.
|
||||||
|
|
||||||
@@ -177,7 +177,7 @@ The scripts are copied to the VHD during the image generation process to the fol
|
|||||||
- **cleanup-logs.sh** - removes all build process logs from the machine
|
- **cleanup-logs.sh** - removes all build process logs from the machine
|
||||||
- **environment-variables.sh** - replaces `$HOME` with the default user's home directory for environmental variables related to the default user home directory
|
- **environment-variables.sh** - replaces `$HOME` with the default user's home directory for environmental variables related to the default user home directory
|
||||||
- **homebrew-permissions.sh** - Resets homebrew repository directory by running `git reset --hard` to make the working tree clean after chmoding /home and changes the repository directory owner to the current user
|
- **homebrew-permissions.sh** - Resets homebrew repository directory by running `git reset --hard` to make the working tree clean after chmoding /home and changes the repository directory owner to the current user
|
||||||
- **rust-permissions.sh** - fixes permissions for the Rust folder. Detailed issue explanation is provided in [virtual-environments/issues/572](https://github.com/actions/virtual-environments/issues/572).
|
- **rust-permissions.sh** - fixes permissions for the Rust folder. Detailed issue explanation is provided in [runner-images/issues/572](https://github.com/actions/runner-images/issues/572).
|
||||||
|
|
||||||
##### Windows
|
##### Windows
|
||||||
|
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ Function GenerateResourcesAndImage {
|
|||||||
.PARAMETER OnError
|
.PARAMETER OnError
|
||||||
Specify how packer handles an error during image creation.
|
Specify how packer handles an error during image creation.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
GenerateResourcesAndImage -SubscriptionId {YourSubscriptionId} -ResourceGroupName "shsamytest1" -ImageGenerationRepositoryRoot "C:\virtual-environments" -ImageType Ubuntu1804 -AzureLocation "East US"
|
GenerateResourcesAndImage -SubscriptionId {YourSubscriptionId} -ResourceGroupName "shsamytest1" -ImageGenerationRepositoryRoot "C:\runner-images" -ImageType Ubuntu1804 -AzureLocation "East US"
|
||||||
#>
|
#>
|
||||||
param (
|
param (
|
||||||
[Parameter(Mandatory = $True)]
|
[Parameter(Mandatory = $True)]
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ function Enable-AutoLogon {
|
|||||||
[string] $Password
|
[string] $Password
|
||||||
)
|
)
|
||||||
|
|
||||||
$url = "https://raw.githubusercontent.com/actions/virtual-environments/main/images/macos/provision/bootstrap-provisioner/setAutoLogin.sh"
|
$url = "https://raw.githubusercontent.com/actions/runner-images/main/images/macos/provision/bootstrap-provisioner/setAutoLogin.sh"
|
||||||
$script = Invoke-RestMethod -Uri $url
|
$script = Invoke-RestMethod -Uri $url
|
||||||
$base64 = [Convert]::ToBase64String($script.ToCharArray())
|
$base64 = [Convert]::ToBase64String($script.ToCharArray())
|
||||||
$command = "echo $base64 | base64 --decode > ./setAutoLogin.sh;sudo bash ./setAutoLogin.sh '${UserName}' '${Password}';rm ./setAutoLogin.sh"
|
$command = "echo $base64 | base64 --decode > ./setAutoLogin.sh;sudo bash ./setAutoLogin.sh '${UserName}' '${Password}';rm ./setAutoLogin.sh"
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ EOF
|
|||||||
apt-get purge unattended-upgrades
|
apt-get purge unattended-upgrades
|
||||||
|
|
||||||
# Need to limit arch for default apt repos due to
|
# Need to limit arch for default apt repos due to
|
||||||
# https://github.com/actions/virtual-environments/issues/1961
|
# https://github.com/actions/runner-images/issues/1961
|
||||||
sed -i'' -E 's/^deb http:\/\/(azure.archive|security).ubuntu.com/deb [arch=amd64,i386] http:\/\/\1.ubuntu.com/' /etc/apt/sources.list
|
sed -i'' -E 's/^deb http:\/\/(azure.archive|security).ubuntu.com/deb [arch=amd64,i386] http:\/\/\1.ubuntu.com/' /etc/apt/sources.list
|
||||||
|
|
||||||
echo 'APT sources limited to the actual architectures'
|
echo 'APT sources limited to the actual architectures'
|
||||||
|
|||||||
@@ -97,7 +97,7 @@ ANDROID_NDK_MAJOR_LATEST=(${ANDROID_NDK_MAJOR_VERSIONS[-1]})
|
|||||||
ndkDefaultFullVersion=$(get_full_ndk_version $ANDROID_NDK_MAJOR_DEFAULT)
|
ndkDefaultFullVersion=$(get_full_ndk_version $ANDROID_NDK_MAJOR_DEFAULT)
|
||||||
ndkLatestFullVersion=$(get_full_ndk_version $ANDROID_NDK_MAJOR_LATEST)
|
ndkLatestFullVersion=$(get_full_ndk_version $ANDROID_NDK_MAJOR_LATEST)
|
||||||
ANDROID_NDK="$ANDROID_SDK_ROOT/ndk/$ndkDefaultFullVersion"
|
ANDROID_NDK="$ANDROID_SDK_ROOT/ndk/$ndkDefaultFullVersion"
|
||||||
# ANDROID_NDK, ANDROID_NDK_HOME, and ANDROID_NDK_ROOT variables should be set as many customer builds depend on them https://github.com/actions/virtual-environments/issues/5879
|
# ANDROID_NDK, ANDROID_NDK_HOME, and ANDROID_NDK_ROOT variables should be set as many customer builds depend on them https://github.com/actions/runner-images/issues/5879
|
||||||
echo "ANDROID_NDK=${ANDROID_NDK}" | tee -a /etc/environment
|
echo "ANDROID_NDK=${ANDROID_NDK}" | tee -a /etc/environment
|
||||||
echo "ANDROID_NDK_HOME=${ANDROID_NDK}" | tee -a /etc/environment
|
echo "ANDROID_NDK_HOME=${ANDROID_NDK}" | tee -a /etc/environment
|
||||||
echo "ANDROID_NDK_ROOT=${ANDROID_NDK}" | tee -a /etc/environment
|
echo "ANDROID_NDK_ROOT=${ANDROID_NDK}" | tee -a /etc/environment
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ echo ImageOS=$IMAGE_OS | tee -a /etc/environment
|
|||||||
# Set the ACCEPT_EULA variable to Y value to confirm your acceptance of the End-User Licensing Agreement
|
# Set the ACCEPT_EULA variable to Y value to confirm your acceptance of the End-User Licensing Agreement
|
||||||
echo ACCEPT_EULA=Y | tee -a /etc/environment
|
echo ACCEPT_EULA=Y | tee -a /etc/environment
|
||||||
|
|
||||||
# This directory is supposed to be created in $HOME and owned by user(https://github.com/actions/virtual-environments/issues/491)
|
# This directory is supposed to be created in $HOME and owned by user(https://github.com/actions/runner-images/issues/491)
|
||||||
mkdir -p /etc/skel/.config/configstore
|
mkdir -p /etc/skel/.config/configstore
|
||||||
echo 'XDG_CONFIG_HOME=$HOME/.config' | tee -a /etc/environment
|
echo 'XDG_CONFIG_HOME=$HOME/.config' | tee -a /etc/environment
|
||||||
|
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ function GetChromiumRevision {
|
|||||||
|
|
||||||
# Some Google Chrome versions are based on Chromium revisions for which a (usually very old) Chromium release with the same number exist. So far this has heppened with 4 digits long Chromium revisions (1060, 1086).
|
# Some Google Chrome versions are based on Chromium revisions for which a (usually very old) Chromium release with the same number exist. So far this has heppened with 4 digits long Chromium revisions (1060, 1086).
|
||||||
# Use the previous Chromium release when this happens to avoid downloading and installing very old Chromium releases that would break image build because of incompatibilities.
|
# Use the previous Chromium release when this happens to avoid downloading and installing very old Chromium releases that would break image build because of incompatibilities.
|
||||||
# First reported with: https://github.com/actions/virtual-environments/issues/5256
|
# First reported with: https://github.com/actions/runner-images/issues/5256
|
||||||
if [ ${#REVISION} -eq 4 ]; then
|
if [ ${#REVISION} -eq 4 ]; then
|
||||||
CURRENT_REVISIONS=$(curl -s "https://omahaproxy.appspot.com/all.json?os=linux&channel=stable")
|
CURRENT_REVISIONS=$(curl -s "https://omahaproxy.appspot.com/all.json?os=linux&channel=stable")
|
||||||
PREVIOUS_VERSION=$(echo "$CURRENT_REVISIONS" | jq -r '.[].versions[].previous_version')
|
PREVIOUS_VERSION=$(echo "$CURRENT_REVISIONS" | jq -r '.[].versions[].previous_version')
|
||||||
@@ -28,7 +28,7 @@ function GetChromiumRevision {
|
|||||||
FIRST_PART_OF_REVISION=${REVISION:0:${#REVISION}/2}
|
FIRST_PART_OF_REVISION=${REVISION:0:${#REVISION}/2}
|
||||||
FIRST_PART_OF_PREVIOUS_REVISION=$(expr $FIRST_PART_OF_REVISION - 1)
|
FIRST_PART_OF_PREVIOUS_REVISION=$(expr $FIRST_PART_OF_REVISION - 1)
|
||||||
URL="https://www.googleapis.com/storage/v1/b/chromium-browser-snapshots/o?delimiter=/&prefix=Linux_x64"
|
URL="https://www.googleapis.com/storage/v1/b/chromium-browser-snapshots/o?delimiter=/&prefix=Linux_x64"
|
||||||
# Revision can include a hash instead of a number. Need to filter it out https://github.com/actions/virtual-environments/issues/5256
|
# Revision can include a hash instead of a number. Need to filter it out https://github.com/actions/runner-images/issues/5256
|
||||||
VERSIONS=$((curl -s $URL/${FIRST_PART_OF_REVISION} | jq -r '.prefixes[]' && curl -s $URL/${FIRST_PART_OF_PREVIOUS_REVISION} | jq -r '.prefixes[]') | grep -E "Linux_x64\/[0-9]+\/"| cut -d "/" -f 2 | sort --version-sort)
|
VERSIONS=$((curl -s $URL/${FIRST_PART_OF_REVISION} | jq -r '.prefixes[]' && curl -s $URL/${FIRST_PART_OF_PREVIOUS_REVISION} | jq -r '.prefixes[]') | grep -E "Linux_x64\/[0-9]+\/"| cut -d "/" -f 2 | sort --version-sort)
|
||||||
|
|
||||||
# If required Chromium revision is not found in the list
|
# If required Chromium revision is not found in the list
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ echo "Creating the symlink for [now] command to vercel CLI"
|
|||||||
ln -s /usr/local/bin/vercel /usr/local/bin/now
|
ln -s /usr/local/bin/vercel /usr/local/bin/now
|
||||||
|
|
||||||
# fix global modules installation as regular user
|
# fix global modules installation as regular user
|
||||||
# related issue https://github.com/actions/virtual-environments/issues/3727
|
# related issue https://github.com/actions/runner-images/issues/3727
|
||||||
sudo chmod -R 777 /usr/local/lib/node_modules
|
sudo chmod -R 777 /usr/local/lib/node_modules
|
||||||
sudo chmod -R 777 /usr/local/bin
|
sudo chmod -R 777 /usr/local/bin
|
||||||
|
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ chmod +x phpunit
|
|||||||
mv phpunit /usr/local/bin/phpunit
|
mv phpunit /usr/local/bin/phpunit
|
||||||
|
|
||||||
# ubuntu 20.04 libzip-dev is libzip5 based and is not compatible libzip-dev of ppa:ondrej/php
|
# ubuntu 20.04 libzip-dev is libzip5 based and is not compatible libzip-dev of ppa:ondrej/php
|
||||||
# see https://github.com/actions/virtual-environments/issues/1084
|
# see https://github.com/actions/runner-images/issues/1084
|
||||||
if isUbuntu20 || isUbuntu22; then
|
if isUbuntu20 || isUbuntu22; then
|
||||||
rm /etc/apt/sources.list.d/ondrej-*.list
|
rm /etc/apt/sources.list.d/ondrej-*.list
|
||||||
apt-get update
|
apt-get update
|
||||||
|
|||||||
@@ -7,10 +7,10 @@ os_version=$(lsb_release -rs)
|
|||||||
image_label="ubuntu-${os_version}"
|
image_label="ubuntu-${os_version}"
|
||||||
version_major=${os_version/.*/}
|
version_major=${os_version/.*/}
|
||||||
version_wo_dot=${os_version/./}
|
version_wo_dot=${os_version/./}
|
||||||
github_url="https://github.com/actions/virtual-environments/blob"
|
github_url="https://github.com/actions/runner-images/blob"
|
||||||
|
|
||||||
software_url="${github_url}/ubuntu${version_major}/${image_version}/images/linux/Ubuntu${version_wo_dot}-Readme.md"
|
software_url="${github_url}/ubuntu${version_major}/${image_version}/images/linux/Ubuntu${version_wo_dot}-Readme.md"
|
||||||
releaseUrl="https://github.com/actions/virtual-environments/releases/tag/ubuntu${version_major}%2F${image_version}"
|
releaseUrl="https://github.com/actions/runner-images/releases/tag/ubuntu${version_major}%2F${image_version}"
|
||||||
|
|
||||||
cat <<EOF > $imagedata_file
|
cat <<EOF > $imagedata_file
|
||||||
[
|
[
|
||||||
|
|||||||
@@ -15,8 +15,8 @@ else
|
|||||||
fi
|
fi
|
||||||
image_label="macos-${label_version}"
|
image_label="macos-${label_version}"
|
||||||
release_label="macOS-${label_version}"
|
release_label="macOS-${label_version}"
|
||||||
software_url="https://github.com/actions/virtual-environments/blob/${release_label}/${image_version}/images/macos/${image_label}-Readme.md"
|
software_url="https://github.com/actions/runner-images/blob/${release_label}/${image_version}/images/macos/${image_label}-Readme.md"
|
||||||
releaseUrl="https://github.com/actions/virtual-environments/releases/tag/${release_label}%2F${image_version}"
|
releaseUrl="https://github.com/actions/runner-images/releases/tag/${release_label}%2F${image_version}"
|
||||||
|
|
||||||
cat <<EOF > $imagedata_file
|
cat <<EOF > $imagedata_file
|
||||||
[
|
[
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ ndkDefault=$(get_full_ndk_version $ANDROID_NDK_MAJOR_DEFAULT)
|
|||||||
ANDROID_NDK_HOME=$ANDROID_HOME/ndk/$ndkDefault
|
ANDROID_NDK_HOME=$ANDROID_HOME/ndk/$ndkDefault
|
||||||
ndkLatest=$(get_full_ndk_version $ANDROID_NDK_MAJOR_LATEST)
|
ndkLatest=$(get_full_ndk_version $ANDROID_NDK_MAJOR_LATEST)
|
||||||
ANDROID_NDK_LATEST_HOME=$ANDROID_HOME/ndk/$ndkLatest
|
ANDROID_NDK_LATEST_HOME=$ANDROID_HOME/ndk/$ndkLatest
|
||||||
# ANDROID_NDK, ANDROID_NDK_HOME, and ANDROID_NDK_ROOT variables should be set as many customer builds depend on them https://github.com/actions/virtual-environments/issues/5879
|
# ANDROID_NDK, ANDROID_NDK_HOME, and ANDROID_NDK_ROOT variables should be set as many customer builds depend on them https://github.com/actions/runner-images/issues/5879
|
||||||
echo "export ANDROID_NDK=$ANDROID_NDK_HOME" >> "${HOME}/.bashrc"
|
echo "export ANDROID_NDK=$ANDROID_NDK_HOME" >> "${HOME}/.bashrc"
|
||||||
echo "export ANDROID_NDK_HOME=$ANDROID_NDK_HOME" >> "${HOME}/.bashrc"
|
echo "export ANDROID_NDK_HOME=$ANDROID_NDK_HOME" >> "${HOME}/.bashrc"
|
||||||
echo "export ANDROID_NDK_ROOT=$ANDROID_NDK_HOME" >> "${HOME}/.bashrc"
|
echo "export ANDROID_NDK_ROOT=$ANDROID_NDK_HOME" >> "${HOME}/.bashrc"
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ bazel
|
|||||||
# Install Azure DevOps extension for Azure Command Line Interface
|
# Install Azure DevOps extension for Azure Command Line Interface
|
||||||
az extension add -n azure-devops
|
az extension add -n azure-devops
|
||||||
|
|
||||||
# Workaround https://github.com/actions/virtual-environments/issues/4931
|
# Workaround https://github.com/actions/runner-images/issues/4931
|
||||||
# by making Tcl/Tk paths the same on macOS 10.15 and macOS 11
|
# by making Tcl/Tk paths the same on macOS 10.15 and macOS 11
|
||||||
if is_BigSur; then
|
if is_BigSur; then
|
||||||
version=$(brew info tcl-tk --json | jq -r '.[].installed[].version')
|
version=$(brew info tcl-tk --json | jq -r '.[].installed[].version')
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ for gccVersion in $gccVersions; do
|
|||||||
brew_smart_install "gcc@${gccVersion}"
|
brew_smart_install "gcc@${gccVersion}"
|
||||||
done
|
done
|
||||||
|
|
||||||
# Delete default gfortran link if it exists https://github.com/actions/virtual-environments/issues/1280
|
# Delete default gfortran link if it exists https://github.com/actions/runner-images/issues/1280
|
||||||
gfortranPath=$(which gfortran)
|
gfortranPath=$(which gfortran)
|
||||||
if [ $gfortranPath ]; then
|
if [ $gfortranPath ]; then
|
||||||
rm $gfortranPath
|
rm $gfortranPath
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ if is_Veertu; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Explicitly overwrite symlinks created by Python2 such as /usr/local/bin/2to3 since they conflict with symlinks from Python3
|
# Explicitly overwrite symlinks created by Python2 such as /usr/local/bin/2to3 since they conflict with symlinks from Python3
|
||||||
# https://github.com/actions/virtual-environments/issues/2322
|
# https://github.com/actions/runner-images/issues/2322
|
||||||
echo "Brew Installing Python 3"
|
echo "Brew Installing Python 3"
|
||||||
brew_smart_install "python@3.9" || brew link --overwrite python@3.9
|
brew_smart_install "python@3.9" || brew link --overwrite python@3.9
|
||||||
|
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ PREFERENCES_XAMARIN_DIR="${HOME}/Library/Preferences/Xamarin"
|
|||||||
mkdir -p $PREFERENCES_XAMARIN_DIR
|
mkdir -p $PREFERENCES_XAMARIN_DIR
|
||||||
/usr/libexec/PlistBuddy -c "add :AppleSdkRoot string /Applications/Xcode_${DEFAULT_XCODE_VERSION}.app" $PREFERENCES_XAMARIN_DIR/Settings.plist
|
/usr/libexec/PlistBuddy -c "add :AppleSdkRoot string /Applications/Xcode_${DEFAULT_XCODE_VERSION}.app" $PREFERENCES_XAMARIN_DIR/Settings.plist
|
||||||
|
|
||||||
# Temporary workaround to recreate nuget.config file with a correct feed https://github.com/actions/virtual-environments/issues/5768
|
# Temporary workaround to recreate nuget.config file with a correct feed https://github.com/actions/runner-images/issues/5768
|
||||||
rm -rf $HOME/.config/NuGet/NuGet.Config
|
rm -rf $HOME/.config/NuGet/NuGet.Config
|
||||||
nuget config
|
nuget config
|
||||||
|
|
||||||
|
|||||||
@@ -239,7 +239,7 @@ function Get-VsixExtenstionFromMarketplace {
|
|||||||
$request -match 'Microsoft\.VisualStudio\.Services\.Payload\.FileName":"(?<filename>[^"]*)' | Out-Null
|
$request -match 'Microsoft\.VisualStudio\.Services\.Payload\.FileName":"(?<filename>[^"]*)' | Out-Null
|
||||||
$fileName = $Matches.filename
|
$fileName = $Matches.filename
|
||||||
$downloadUri = $assetUri + "/" + $fileName
|
$downloadUri = $assetUri + "/" + $fileName
|
||||||
# ProBITools.MicrosoftReportProjectsforVisualStudio2022 has different URL https://github.com/actions/virtual-environments/issues/5340
|
# ProBITools.MicrosoftReportProjectsforVisualStudio2022 has different URL https://github.com/actions/runner-images/issues/5340
|
||||||
switch ($ExtensionMarketPlaceName) {
|
switch ($ExtensionMarketPlaceName) {
|
||||||
"ProBITools.MicrosoftReportProjectsforVisualStudio2022" {
|
"ProBITools.MicrosoftReportProjectsforVisualStudio2022" {
|
||||||
$fileName = "Microsoft.DataTools.ReportingServices.vsix"
|
$fileName = "Microsoft.DataTools.ReportingServices.vsix"
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ $avPreference | Foreach-Object {
|
|||||||
Write-Host "Disable Windows Defender scheduled tasks"
|
Write-Host "Disable Windows Defender scheduled tasks"
|
||||||
Get-ScheduledTask -TaskPath '\Microsoft\Windows\Windows Defender\' | Disable-ScheduledTask | Out-Null
|
Get-ScheduledTask -TaskPath '\Microsoft\Windows\Windows Defender\' | Disable-ScheduledTask | Out-Null
|
||||||
|
|
||||||
# https://github.com/actions/virtual-environments/issues/4277
|
# https://github.com/actions/runner-images/issues/4277
|
||||||
# https://docs.microsoft.com/en-us/microsoft-365/security/defender-endpoint/microsoft-defender-antivirus-compatibility?view=o365-worldwide
|
# https://docs.microsoft.com/en-us/microsoft-365/security/defender-endpoint/microsoft-defender-antivirus-compatibility?view=o365-worldwide
|
||||||
$atpRegPath = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows Advanced Threat Protection'
|
$atpRegPath = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows Advanced Threat Protection'
|
||||||
if (Test-Path $atpRegPath) {
|
if (Test-Path $atpRegPath) {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ Write-Host "Cleanup WinSxS"
|
|||||||
Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase
|
Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase
|
||||||
|
|
||||||
# Sets the default install version to v1 for new distributions
|
# Sets the default install version to v1 for new distributions
|
||||||
# https://github.com/actions/virtual-environments/issues/5760
|
# https://github.com/actions/runner-images/issues/5760
|
||||||
if (Test-IsWin22) {
|
if (Test-IsWin22) {
|
||||||
Write-Host "Sets the default install version to v1 for new distributions"
|
Write-Host "Sets the default install version to v1 for new distributions"
|
||||||
Add-DefaultItem -DefaultVariable "DefaultVersion" -Value 1 -Name "DEFAULT\Software\Microsoft\Windows\CurrentVersion\Lxss" -Kind "DWord"
|
Add-DefaultItem -DefaultVariable "DefaultVersion" -Value 1 -Name "DEFAULT\Software\Microsoft\Windows\CurrentVersion\Lxss" -Kind "DWord"
|
||||||
@@ -40,7 +40,7 @@ cmd /c "yarn cache clean 2>&1" | Out-Null
|
|||||||
cmd /c "npm cache clean --force 2>&1" | Out-Null
|
cmd /c "npm cache clean --force 2>&1" | Out-Null
|
||||||
|
|
||||||
# allow msi to write to temp folder
|
# allow msi to write to temp folder
|
||||||
# see https://github.com/actions/virtual-environments/issues/1704
|
# see https://github.com/actions/runner-images/issues/1704
|
||||||
cmd /c "icacls $env:SystemRoot\Temp /grant Users:f /t /c /q 2>&1" | Out-Null
|
cmd /c "icacls $env:SystemRoot\Temp /grant Users:f /t /c /q 2>&1" | Out-Null
|
||||||
|
|
||||||
# Registry settings
|
# Registry settings
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ Invoke-SBWithRetry -Command {
|
|||||||
Rename-Item "${sdkInstallRoot}\cmdline-tools\cmdline-tools" "latest" -ErrorAction Stop
|
Rename-Item "${sdkInstallRoot}\cmdline-tools\cmdline-tools" "latest" -ErrorAction Stop
|
||||||
}
|
}
|
||||||
|
|
||||||
# ANDROID_NDK_PATH/HOME should not contain spaces. Otherwise, the script ndk-build.cmd gives an error https://github.com/actions/virtual-environments/issues/1122
|
# ANDROID_NDK_PATH/HOME should not contain spaces. Otherwise, the script ndk-build.cmd gives an error https://github.com/actions/runner-images/issues/1122
|
||||||
# create "C:\Android" directory and a hardlink inside pointed to sdk in Program Files
|
# create "C:\Android" directory and a hardlink inside pointed to sdk in Program Files
|
||||||
New-Item -Path "C:\Android" -ItemType Directory
|
New-Item -Path "C:\Android" -ItemType Directory
|
||||||
New-Item -Path "$sdkRoot" -ItemType SymbolicLink -Value "$sdkInstallRoot"
|
New-Item -Path "$sdkRoot" -ItemType SymbolicLink -Value "$sdkInstallRoot"
|
||||||
@@ -127,7 +127,7 @@ $ndkRoot = "$sdkRoot\ndk\$ndkDefaultVersion"
|
|||||||
# Create env variables
|
# Create env variables
|
||||||
setx ANDROID_HOME $sdkRoot /M
|
setx ANDROID_HOME $sdkRoot /M
|
||||||
setx ANDROID_SDK_ROOT $sdkRoot /M
|
setx ANDROID_SDK_ROOT $sdkRoot /M
|
||||||
# ANDROID_NDK, ANDROID_NDK_HOME, and ANDROID_NDK_ROOT variables should be set as many customer builds depend on them https://github.com/actions/virtual-environments/issues/5879
|
# ANDROID_NDK, ANDROID_NDK_HOME, and ANDROID_NDK_ROOT variables should be set as many customer builds depend on them https://github.com/actions/runner-images/issues/5879
|
||||||
setx ANDROID_NDK $ndkRoot /M
|
setx ANDROID_NDK $ndkRoot /M
|
||||||
setx ANDROID_NDK_HOME $ndkRoot /M
|
setx ANDROID_NDK_HOME $ndkRoot /M
|
||||||
setx ANDROID_NDK_ROOT $ndkRoot /M
|
setx ANDROID_NDK_ROOT $ndkRoot /M
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ function Install-JavaJDK {
|
|||||||
$downloadUrl = $asset.binary.package.link
|
$downloadUrl = $asset.binary.package.link
|
||||||
$archivePath = Start-DownloadWithRetry -Url $downloadUrl -Name $([IO.Path]::GetFileName($downloadUrl))
|
$archivePath = Start-DownloadWithRetry -Url $downloadUrl -Name $([IO.Path]::GetFileName($downloadUrl))
|
||||||
|
|
||||||
# We have to replace '+' sign in the version to '-' due to the issue with incorrect path in Android builds https://github.com/actions/virtual-environments/issues/3014
|
# We have to replace '+' sign in the version to '-' due to the issue with incorrect path in Android builds https://github.com/actions/runner-images/issues/3014
|
||||||
$fullJavaVersion = $asset.version.semver -replace '\+', '-'
|
$fullJavaVersion = $asset.version.semver -replace '\+', '-'
|
||||||
# Create directories in toolcache path
|
# Create directories in toolcache path
|
||||||
$javaToolcachePath = Join-Path -Path $env:AGENT_TOOLSDIRECTORY -ChildPath "Java_${VendorName}_jdk"
|
$javaToolcachePath = Join-Path -Path $env:AGENT_TOOLSDIRECTORY -ChildPath "Java_${VendorName}_jdk"
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ if (-not $vsixPackagesList) {
|
|||||||
|
|
||||||
$vsVersion = $toolset.visualStudio.Version
|
$vsVersion = $toolset.visualStudio.Version
|
||||||
$vsixPackagesList | ForEach-Object {
|
$vsixPackagesList | ForEach-Object {
|
||||||
# Retrieve cdn endpoint to avoid HTTP error 429 https://github.com/actions/virtual-environments/issues/3074
|
# Retrieve cdn endpoint to avoid HTTP error 429 https://github.com/actions/runner-images/issues/3074
|
||||||
$vsixPackage = Get-VsixExtenstionFromMarketplace -ExtensionMarketPlaceName $_
|
$vsixPackage = Get-VsixExtenstionFromMarketplace -ExtensionMarketPlaceName $_
|
||||||
if ($vsixPackage.FileName.EndsWith(".vsix")) {
|
if ($vsixPackage.FileName.EndsWith(".vsix")) {
|
||||||
Install-VsixExtension -Url $vsixPackage.DownloadUri -Name $vsixPackage.FileName -VSversion $vsVersion
|
Install-VsixExtension -Url $vsixPackage.DownloadUri -Name $vsixPackage.FileName -VSversion $vsVersion
|
||||||
|
|||||||
@@ -5,16 +5,16 @@ $osEdition = $caption.Substring($caption.LastIndexOf(" ")+1)
|
|||||||
$osVersion = $os.Version
|
$osVersion = $os.Version
|
||||||
$imageVersion = $env:IMAGE_VERSION
|
$imageVersion = $env:IMAGE_VERSION
|
||||||
$imageDataFile = $env:IMAGEDATA_FILE
|
$imageDataFile = $env:IMAGEDATA_FILE
|
||||||
$githubUrl="https://github.com/actions/virtual-environments/blob"
|
$githubUrl="https://github.com/actions/runner-images/blob"
|
||||||
|
|
||||||
if (Test-IsWin22) {
|
if (Test-IsWin22) {
|
||||||
$imageLabel = "windows-2022"
|
$imageLabel = "windows-2022"
|
||||||
$softwareUrl = "${githubUrl}/win22/${imageVersion}/images/win/Windows2022-Readme.md"
|
$softwareUrl = "${githubUrl}/win22/${imageVersion}/images/win/Windows2022-Readme.md"
|
||||||
$releaseUrl="https://github.com/actions/virtual-environments/releases/tag/win22%2F${imageVersion}"
|
$releaseUrl="https://github.com/actions/runner-images/releases/tag/win22%2F${imageVersion}"
|
||||||
} elseif (Test-IsWin19) {
|
} elseif (Test-IsWin19) {
|
||||||
$imageLabel = "windows-2019"
|
$imageLabel = "windows-2019"
|
||||||
$softwareUrl = "${githubUrl}/win19/${imageVersion}/images/win/Windows2019-Readme.md"
|
$softwareUrl = "${githubUrl}/win19/${imageVersion}/images/win/Windows2019-Readme.md"
|
||||||
$releaseUrl="https://github.com/actions/virtual-environments/releases/tag/win19%2F${imageVersion}"
|
$releaseUrl="https://github.com/actions/runner-images/releases/tag/win19%2F${imageVersion}"
|
||||||
} else {
|
} else {
|
||||||
throw "Invalid platform version is found. Either Windows Server 2019 or 2022 are required"
|
throw "Invalid platform version is found. Either Windows Server 2019 or 2022 are required"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ function Get-JavaVersions {
|
|||||||
return $javaVersions | Sort-Object $sortRules | ForEach-Object {
|
return $javaVersions | Sort-Object $sortRules | ForEach-Object {
|
||||||
$javaPath = $_.Value
|
$javaPath = $_.Value
|
||||||
# Take semver from the java path
|
# Take semver from the java path
|
||||||
# The path contains '-' sign in the version number instead of '+' due to the following issue, need to substitute it back https://github.com/actions/virtual-environments/issues/3014
|
# The path contains '-' sign in the version number instead of '+' due to the following issue, need to substitute it back https://github.com/actions/runner-images/issues/3014
|
||||||
$versionInPath = (Split-Path $javaPath) -replace "\w:\\.*\\"
|
$versionInPath = (Split-Path $javaPath) -replace "\w:\\.*\\"
|
||||||
$version = $versionInPath -replace '-', '+'
|
$version = $versionInPath -replace '-', '+'
|
||||||
$defaultPostfix = ($javaPath -eq $defaultJavaPath) ? " (default)" : ""
|
$defaultPostfix = ($javaPath -eq $defaultJavaPath) ? " (default)" : ""
|
||||||
|
|||||||
Reference in New Issue
Block a user