mirror of
https://github.com/actions/runner-images.git
synced 2025-12-17 23:28:57 +00:00
[Ubuntu] use pipx to install ansible (#3015)
* use pipx to install ansible * update info
This commit is contained in:
committed by
GitHub
parent
ecfee9c8ec
commit
436d9baa95
@@ -4,16 +4,11 @@
|
|||||||
## Desc: Installs Ansible
|
## Desc: Installs Ansible
|
||||||
################################################################################
|
################################################################################
|
||||||
|
|
||||||
# Source the helpers for use with the script
|
# this script is used only on Ubuntu 16.04
|
||||||
source $HELPER_SCRIPTS/os.sh
|
# for Ubuntu 18.04 and 20.04 we use pipx ansible-base package
|
||||||
|
|
||||||
# ppa:ansible/ansible doesn't contain packages for Ubuntu20.04
|
|
||||||
if isUbuntu16 || isUbuntu18 ; then
|
|
||||||
add-apt-repository ppa:ansible/ansible
|
|
||||||
apt-get update
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Install latest Ansible
|
# Install latest Ansible
|
||||||
|
add-apt-repository ppa:ansible/ansible
|
||||||
|
apt-get update
|
||||||
apt-get install -y --no-install-recommends ansible
|
apt-get install -y --no-install-recommends ansible
|
||||||
|
|
||||||
invoke_tests "Tools" "Ansible"
|
invoke_tests "Tools" "Ansible"
|
||||||
|
|||||||
@@ -43,6 +43,6 @@ Describe "PipxPackages" -Skip:(Test-IsUbuntu16) {
|
|||||||
[array]$testCases = (Get-ToolsetContent).pipx | ForEach-Object { @{cmd = $_.cmd} }
|
[array]$testCases = (Get-ToolsetContent).pipx | ForEach-Object { @{cmd = $_.cmd} }
|
||||||
|
|
||||||
It "<package>" -TestCases $testCases {
|
It "<package>" -TestCases $testCases {
|
||||||
"$cmd --version" | Should -ReturnZeroExitCode
|
"$cmd --version" | Should -ReturnZeroExitCode
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -218,6 +218,10 @@
|
|||||||
{
|
{
|
||||||
"package": "aws-sam-cli",
|
"package": "aws-sam-cli",
|
||||||
"cmd": "sam"
|
"cmd": "sam"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"package": "ansible-base",
|
||||||
|
"cmd": "ansible"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"dotnet": {
|
"dotnet": {
|
||||||
|
|||||||
@@ -219,6 +219,10 @@
|
|||||||
{
|
{
|
||||||
"package": "aws-sam-cli",
|
"package": "aws-sam-cli",
|
||||||
"cmd": "sam"
|
"cmd": "sam"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"package": "ansible-base",
|
||||||
|
"cmd": "ansible"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"dotnet": {
|
"dotnet": {
|
||||||
|
|||||||
@@ -188,7 +188,6 @@
|
|||||||
{
|
{
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"scripts": [
|
"scripts": [
|
||||||
"{{template_dir}}/scripts/installers/ansible.sh",
|
|
||||||
"{{template_dir}}/scripts/installers/azcopy.sh",
|
"{{template_dir}}/scripts/installers/azcopy.sh",
|
||||||
"{{template_dir}}/scripts/installers/azure-cli.sh",
|
"{{template_dir}}/scripts/installers/azure-cli.sh",
|
||||||
"{{template_dir}}/scripts/installers/azure-devops-cli.sh",
|
"{{template_dir}}/scripts/installers/azure-devops-cli.sh",
|
||||||
|
|||||||
@@ -188,7 +188,6 @@
|
|||||||
{
|
{
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"scripts": [
|
"scripts": [
|
||||||
"{{template_dir}}/scripts/installers/ansible.sh",
|
|
||||||
"{{template_dir}}/scripts/installers/azcopy.sh",
|
"{{template_dir}}/scripts/installers/azcopy.sh",
|
||||||
"{{template_dir}}/scripts/installers/azure-cli.sh",
|
"{{template_dir}}/scripts/installers/azure-cli.sh",
|
||||||
"{{template_dir}}/scripts/installers/azure-devops-cli.sh",
|
"{{template_dir}}/scripts/installers/azure-devops-cli.sh",
|
||||||
|
|||||||
Reference in New Issue
Block a user