diff --git a/images.CI/linux-and-win/build-image.ps1 b/images.CI/linux-and-win/build-image.ps1 index 7abfdfd9..f1c4ce60 100644 --- a/images.CI/linux-and-win/build-image.ps1 +++ b/images.CI/linux-and-win/build-image.ps1 @@ -10,7 +10,8 @@ param( [String] [Parameter (Mandatory=$true)] $TenantId, [String] [Parameter (Mandatory=$false)] $VirtualNetworkName, [String] [Parameter (Mandatory=$false)] $VirtualNetworkRG, - [String] [Parameter (Mandatory=$false)] $VirtualNetworkSubnet + [String] [Parameter (Mandatory=$false)] $VirtualNetworkSubnet, + [String] [Parameter (Mandatory=$false)] $AllowedInboundIpAddresses = "[]" ) if (-not (Test-Path $TemplatePath)) @@ -54,6 +55,7 @@ packer build -var "client_id=$ClientId" ` -var "virtual_network_name=$VirtualNetworkName" ` -var "virtual_network_resource_group_name=$VirtualNetworkRG" ` -var "virtual_network_subnet_name=$VirtualNetworkSubnet" ` + -var "allowed_inbound_ip_addresses=$($AllowedInboundIpAddresses)" ` -color=false ` $TemplatePath ` | Where-Object { diff --git a/images/ubuntu/scripts/build/install-azure-cli.sh b/images/ubuntu/scripts/build/install-azure-cli.sh index 1791755c..0004f7bd 100644 --- a/images/ubuntu/scripts/build/install-azure-cli.sh +++ b/images/ubuntu/scripts/build/install-azure-cli.sh @@ -12,11 +12,4 @@ echo "azure-cli https://docs.microsoft.com/en-us/cli/azure/install-azure-cli-lin rm -f /etc/apt/sources.list.d/azure-cli.list rm -f /etc/apt/sources.list.d/azure-cli.list.save -echo "Warmup 'az'" -az --help > /dev/null -if [ $? -ne 0 ]; then - echo "Command 'az --help' failed" - exit 1 -fi - invoke_tests "CLI.Tools" "Azure CLI" diff --git a/images/ubuntu/scripts/build/install-docker-compose.sh b/images/ubuntu/scripts/build/install-docker-compose.sh deleted file mode 100644 index 4d152c77..00000000 --- a/images/ubuntu/scripts/build/install-docker-compose.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -e -################################################################################ -## File: install-docker-compose.sh -## Desc: Install Docker Compose v1 -## Supply chain security: Docker Compose v1 - checksum validation -################################################################################ - -# Source the helpers for use with the script -source $HELPER_SCRIPTS/install.sh - -# Download docker-compose v1 from releases -binary_path=$(download_with_retry "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-Linux-x86_64") - -# Supply chain security - Docker Compose v1 -external_hash="f3f10cf3dbb8107e9ba2ea5f23c1d2159ff7321d16f0a23051d68d8e2547b323" -use_checksum_comparison "${binary_path}" "${external_hash}" - -# Install docker-compose v1 -install "${binary_path}" "/usr/local/bin/docker-compose" - -invoke_tests "Tools" "Docker-compose v1" diff --git a/images/ubuntu/scripts/docs-gen/Generate-SoftwareReport.ps1 b/images/ubuntu/scripts/docs-gen/Generate-SoftwareReport.ps1 index 3d335752..0688c805 100644 --- a/images/ubuntu/scripts/docs-gen/Generate-SoftwareReport.ps1 +++ b/images/ubuntu/scripts/docs-gen/Generate-SoftwareReport.ps1 @@ -111,9 +111,6 @@ $tools.AddToolVersion("Buildah", $(Get-BuildahVersion)) $tools.AddToolVersion("CMake", $(Get-CMakeVersion)) $tools.AddToolVersion("CodeQL Action Bundle", $(Get-CodeQLBundleVersion)) $tools.AddToolVersion("Docker Amazon ECR Credential Helper", $(Get-DockerAmazonECRCredHelperVersion)) -if ((Test-IsUbuntu20) -or (Test-IsUbuntu22)) { - $tools.AddToolVersion("Docker Compose v1", $(Get-DockerComposeV1Version)) -} $tools.AddToolVersion("Docker Compose v2", $(Get-DockerComposeV2Version)) $tools.AddToolVersion("Docker-Buildx", $(Get-DockerBuildxVersion)) $tools.AddToolVersion("Docker Client", $(Get-DockerClientVersion)) diff --git a/images/ubuntu/scripts/docs-gen/SoftwareReport.Common.psm1 b/images/ubuntu/scripts/docs-gen/SoftwareReport.Common.psm1 index 62e39cae..73e3e1f3 100644 --- a/images/ubuntu/scripts/docs-gen/SoftwareReport.Common.psm1 +++ b/images/ubuntu/scripts/docs-gen/SoftwareReport.Common.psm1 @@ -131,7 +131,7 @@ function Get-LernaVersion { } function Get-HomebrewVersion { - $result = Get-CommandResult "/home/linuxbrew/.linuxbrew/bin/brew -v" + $result = Get-CommandResult "/home/linuxbrew/.linuxbrew/bin/brew --version" $result.Output -match "Homebrew (?\d+\.\d+\.\d+)" | Out-Null return $Matches.version } diff --git a/images/ubuntu/scripts/docs-gen/SoftwareReport.Tools.psm1 b/images/ubuntu/scripts/docs-gen/SoftwareReport.Tools.psm1 index a61b0a8d..b4656b77 100644 --- a/images/ubuntu/scripts/docs-gen/SoftwareReport.Tools.psm1 +++ b/images/ubuntu/scripts/docs-gen/SoftwareReport.Tools.psm1 @@ -58,10 +58,7 @@ function Get-CMakeVersion { return $cmakeVersion } -function Get-DockerComposeV1Version { - $composeVersion = docker-compose -v | Get-StringPart -Part 2 | Get-StringPart -Part 0 -Delimiter "," - return $composeVersion -} + function Get-DockerComposeV2Version { $composeVersion = docker compose version | Get-StringPart -Part 3 | Get-StringPart -Part 0 -Delimiter "v" diff --git a/images/ubuntu/scripts/tests/Tools.Tests.ps1 b/images/ubuntu/scripts/tests/Tools.Tests.ps1 index 6e6ec0af..cb9c0730 100644 --- a/images/ubuntu/scripts/tests/Tools.Tests.ps1 +++ b/images/ubuntu/scripts/tests/Tools.Tests.ps1 @@ -121,12 +121,6 @@ Describe "Docker images" { } } -Describe "Docker-compose v1" -Skip:((-not (Test-IsUbuntu20)) -and (-not (Test-IsUbuntu22))) { - It "docker-compose" { - "docker-compose --version"| Should -ReturnZeroExitCode - } -} - Describe "Ansible" { It "Ansible" { "ansible --version" | Should -ReturnZeroExitCode diff --git a/images/ubuntu/templates/ubuntu-20.04.pkr.hcl b/images/ubuntu/templates/ubuntu-20.04.pkr.hcl index 101c5a3b..d8d821bc 100644 --- a/images/ubuntu/templates/ubuntu-20.04.pkr.hcl +++ b/images/ubuntu/templates/ubuntu-20.04.pkr.hcl @@ -344,7 +344,7 @@ build { provisioner "shell" { environment_vars = ["HELPER_SCRIPTS=${var.helper_script_folder}", "INSTALLER_SCRIPT_FOLDER=${var.installer_script_folder}", "DOCKERHUB_LOGIN=${var.dockerhub_login}", "DOCKERHUB_PASSWORD=${var.dockerhub_password}"] execute_command = "sudo sh -c '{{ .Vars }} {{ .Path }}'" - scripts = ["${path.root}/../scripts/build/install-docker-compose.sh", "${path.root}/../scripts/build/install-docker.sh"] + scripts = ["${path.root}/../scripts/build/install-docker.sh"] } provisioner "shell" { diff --git a/images/ubuntu/templates/ubuntu-22.04.pkr.hcl b/images/ubuntu/templates/ubuntu-22.04.pkr.hcl index 9b881a68..6dd0abf1 100644 --- a/images/ubuntu/templates/ubuntu-22.04.pkr.hcl +++ b/images/ubuntu/templates/ubuntu-22.04.pkr.hcl @@ -340,7 +340,7 @@ build { provisioner "shell" { environment_vars = ["HELPER_SCRIPTS=${var.helper_script_folder}", "INSTALLER_SCRIPT_FOLDER=${var.installer_script_folder}", "DOCKERHUB_LOGIN=${var.dockerhub_login}", "DOCKERHUB_PASSWORD=${var.dockerhub_password}"] execute_command = "sudo sh -c '{{ .Vars }} {{ .Path }}'" - scripts = ["${path.root}/../scripts/build/install-docker-compose.sh", "${path.root}/../scripts/build/install-docker.sh"] + scripts = ["${path.root}/../scripts/build/install-docker.sh"] } provisioner "shell" { diff --git a/images/windows/toolsets/toolset-2019.json b/images/windows/toolsets/toolset-2019.json index 71755ce8..06e41169 100644 --- a/images/windows/toolsets/toolset-2019.json +++ b/images/windows/toolsets/toolset-2019.json @@ -84,7 +84,7 @@ {"name": "PowerShellGet"}, {"name": "PSScriptAnalyzer"}, {"name": "PSWindowsUpdate"}, - {"name": "SqlServer"}, + {"name": "SqlServer", "versions": ["22.2.0"]}, {"name": "VSSetup"}, {"name": "Microsoft.Graph"}, {"name": "AWSPowershell"} @@ -424,7 +424,7 @@ { "name": "aria2" }, { "name": "azcopy10" }, { "name": "Bicep" }, - { "name": "gitversion.portable" }, + { "name": "gitversion.portable", "args": [ "--version", "5.12.0"] }, { "name": "innosetup" }, { "name": "jq" }, { "name": "NuGet.CommandLine" },