Skip to content

Commit

Permalink
fix: update Finch on Windows rootfs update workflow
Browse files Browse the repository at this point in the history
This change updates the find artifact in s3 utility function to use
grep's extended regex and updates the rootfs and lima bundle filename
patterns for it.

Signed-off-by: Austin Vazquez <macedonv@amazon.com>
  • Loading branch information
austinvazquez committed Jun 26, 2024
1 parent 772bd43 commit 76acac3
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions bin/update-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ PROJECT_ROOT="$(cd -- "${CURRENT_DIR}/.." && pwd)"
source "${PROJECT_ROOT}/bin/utility.sh"

DEPENDENCY_CLOUDFRONT_URL="https://deps.runfinch.com"
AARCH64_FILENAME_PATTERN="lima-and-qemu.macos-aarch64.[0-9].*\.gz$"
AMD64_FILENAME_PATTERN="lima-and-qemu.macos-x86_64.[0-9].*\.gz$"
AARCH64_FILENAME_PATTERN="lima-and-qemu.macos-aarch64\.[0-9]+\.tar\.gz$"
AMD64_FILENAME_PATTERN="lima-and-qemu.macos-x86_64\.[0-9]+\.tar\.gz$"
AARCH64="aarch64"
X86_64="x86-64"

Expand Down
2 changes: 1 addition & 1 deletion bin/update-rootfs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ PROJECT_ROOT="$(cd -- "${CURRENT_DIR}/.." && pwd)"
source "${PROJECT_ROOT}/bin/utility.sh"

DEPENDENCY_CLOUDFRONT_URL="https://deps.runfinch.com"
AMD64_FILENAME_PATTERN="finch-rootfs-production-amd64-[0-9]+\.tar.gz"
AMD64_FILENAME_PATTERN="finch-rootfs-production-amd64-[0-9]+\.tar\.gz$"
PLATFORM="common"
# ARM not currently supported for Finch on Windows
# AARCH64="aarch64"
Expand Down
2 changes: 1 addition & 1 deletion bin/utility.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ find_latest_object_match_from_s3() {
local object_pattern="$1"
local s3_bucket="$2"

object=$(aws s3 ls "s3://${s3_bucket}" --recursive | grep "${object_pattern}" | sort | tail -n 1 | awk '{print $4}')
object=$(aws s3 ls "s3://${s3_bucket}" --recursive | grep -E "${object_pattern}" | sort | tail -n 1 | awk '{print $4}')
if [[ -z "$object" ]]; then
echo "error: no match found for pattern ${object_pattern}"
exit 1
Expand Down

0 comments on commit 76acac3

Please sign in to comment.