Skip to content

Commit

Permalink
Merge branch 'actions:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
dray92 authored Jan 7, 2025
2 parents 49d47fc + 3d5f09a commit a8bf922
Show file tree
Hide file tree
Showing 7 changed files with 48 additions and 20 deletions.
7 changes: 7 additions & 0 deletions images/ubuntu/scripts/build/cleanup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,13 @@ if command -v journalctl; then
journalctl --vacuum-time=1s
fi

# remove redundant folders from azcli
if [[ -z "${AZURE_CONFIG_DIR}" ]]; then
rm -rf $AZURE_CONFIG_DIR/logs
rm -rf $AZURE_CONFIG_DIR/commands
rm -rf $AZURE_CONFIG_DIR/telemetry
fi

# delete all .gz and rotated file
find /var/log -type f -regex ".*\.gz$" -delete
find /var/log -type f -regex ".*\.[0-9]$" -delete
Expand Down
32 changes: 30 additions & 2 deletions images/ubuntu/scripts/build/install-azure-cli.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,40 @@
## Desc: Install Azure CLI (az)
################################################################################

# Source the helpers for use with the script
source $HELPER_SCRIPTS/etc-environment.sh

# AZURE_CONFIG_DIR shell variable defines where the CLI configuration file for managing behavior are stored
# https://learn.microsoft.com/en-us/cli/azure/azure-cli-configuration#cli-configuration-file
# This path SHOULD be different from the installation directory /opt/az/
export AZURE_CONFIG_DIR="/opt/az-config"
mkdir -p $AZURE_CONFIG_DIR
set_etc_environment_variable "AZURE_CONFIG_DIR" "${AZURE_CONFIG_DIR}"

# AZURE_EXTENSION_DIR shell variable defines where modules are installed
# https://docs.microsoft.com/en-us/cli/azure/azure-cli-extensions-overview
# This path SHOULD be different from the installation directory /opt/az/
export AZURE_EXTENSION_DIR="/opt/az-extension"
mkdir -p $AZURE_EXTENSION_DIR
set_etc_environment_variable "AZURE_EXTENSION_DIR" "${AZURE_EXTENSION_DIR}"

# Install Azure CLI (instructions taken from https://docs.microsoft.com/en-us/cli/azure/install-azure-cli)
curl -fsSL https://aka.ms/InstallAzureCLIDeb | sudo bash

echo "azure-cli https://docs.microsoft.com/en-us/cli/azure/install-azure-cli-linux?pivots=apt" >> $HELPER_SCRIPTS/apt-sources.txt

rm -f /etc/apt/sources.list.d/azure-cli.list
rm -f /etc/apt/sources.list.d/azure-cli.list.save
# Remove Azure CLI repository (instructions taken from https://learn.microsoft.com/en-us/cli/azure/install-azure-cli-linux?pivots=apt#uninstall-azure-cli)
rm -f /etc/apt/sources.list.d/azure-cli.sources

echo "Warmup 'az'"
az --help > /dev/null
if [ $? -ne 0 ]; then
echo "Command 'az --help' failed"
exit 1
fi

# Hand over the ownership of the directories and files to the non-root user
chown -R "$SUDO_USER:$SUDO_USER" $AZURE_CONFIG_DIR
chown -R "$SUDO_USER:$SUDO_USER" $AZURE_EXTENSION_DIR

invoke_tests "CLI.Tools" "Azure CLI"
8 changes: 0 additions & 8 deletions images/ubuntu/scripts/build/install-azure-devops-cli.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,6 @@
## Desc: Install Azure DevOps CLI (az devops)
################################################################################

# Source the helpers for use with the script
source $HELPER_SCRIPTS/etc-environment.sh

# AZURE_EXTENSION_DIR shell variable defines where modules are installed
# https://docs.microsoft.com/en-us/cli/azure/azure-cli-extensions-overview
export AZURE_EXTENSION_DIR=/opt/az/azcliextensions
set_etc_environment_variable "AZURE_EXTENSION_DIR" "${AZURE_EXTENSION_DIR}"

# install azure devops Cli extension
az extension add -n azure-devops

Expand Down
4 changes: 2 additions & 2 deletions images/ubuntu/scripts/build/install-zstd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ use_checksum_comparison "$archive_path" "$external_hash"
apt-get install liblz4-dev
tar xzf "$archive_path" -C /tmp

make -C "/tmp/${release_name}/contrib/pzstd" all
make -C "/tmp/${release_name}" zstd-release
make -C "/tmp/${release_name}/contrib/pzstd" -j $(nproc) all
make -C "/tmp/${release_name}" -j $(nproc) zstd-release

for copyprocess in zstd zstdless zstdgrep; do
cp "/tmp/${release_name}/programs/${copyprocess}" /usr/local/bin/
Expand Down
1 change: 1 addition & 0 deletions images/ubuntu/toolsets/toolset-2404.json
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@
"libyaml-dev",
"libtool",
"libssl-dev",
"libsqlite3-dev",
"locales",
"mercurial",
"openssh-client",
Expand Down
8 changes: 4 additions & 4 deletions images/windows/toolsets/toolset-2019.json
Original file line number Diff line number Diff line change
Expand Up @@ -397,12 +397,12 @@
},
"serviceFabric": {
"runtime": {
"version": "9.1.1436.9590",
"checksum": "089F9BE6A63AF66C337E507B52082575C8ED330DF765259C6F2F13F900DA96D5"
"version": "9.1.2837.9590",
"checksum": "5CDFDC7497522147081C7FB0CEBE09E483F871285A8EB87C821F1AB64DD9FCDD"
},
"sdk": {
"version": "6.1.1436",
"checksum": "D2A6B58315D08B6E46C2D25E91DFA1163136F70A5FA8CEF9DB147F07EE001AD1"
"version": "6.1.2837",
"checksum": "492F2FCE79C409ADAFC34F581956505C454484E909814E8FEF413DA10457D232"
}
},
"dotnet": {
Expand Down
8 changes: 4 additions & 4 deletions images/windows/toolsets/toolset-2022.json
Original file line number Diff line number Diff line change
Expand Up @@ -308,12 +308,12 @@
},
"serviceFabric": {
"runtime": {
"version": "9.1.1436.9590",
"checksum": "089F9BE6A63AF66C337E507B52082575C8ED330DF765259C6F2F13F900DA96D5"
"version": "9.1.2837.9590",
"checksum": "5CDFDC7497522147081C7FB0CEBE09E483F871285A8EB87C821F1AB64DD9FCDD"
},
"sdk": {
"version": "6.1.1436",
"checksum": "D2A6B58315D08B6E46C2D25E91DFA1163136F70A5FA8CEF9DB147F07EE001AD1"
"version": "6.1.2837",
"checksum": "492F2FCE79C409ADAFC34F581956505C454484E909814E8FEF413DA10457D232"
}
},
"dotnet": {
Expand Down

0 comments on commit a8bf922

Please # to comment.