Skip to content

Commit 0db19af

Browse files
committed
amazon linux 2023 support
1 parent ac442dd commit 0db19af

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060

6161
- name: Set and Calculate test vars
6262
run: |
63-
echo "instance_hostname=ubuntu@${{ steps.get_public_dns_name.outputs.result }}" >> $GITHUB_ENV
63+
echo "instance_hostname=ec2-user@${{ steps.get_public_dns_name.outputs.result }}" >> $GITHUB_ENV
6464
echo "private_key=${{ github.workspace }}/key.pem" >> $GITHUB_ENV
6565
echo "${{ secrets.AWS_SSH_KEY }}" > ${{ github.workspace }}/key.pem && chmod 400 ${{ github.workspace }}/key.pem
6666
echo "COMMIT_SHORT_SHA=${GITHUB_SHA:0:8}" >> $GITHUB_ENV

amzn2023/nvidia-driver

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ echo "DRIVER_ARCH is $DRIVER_ARCH"
2828
_update_package_cache() {
2929
if [ "${PACKAGE_TAG:-}" != "builtin" ]; then
3030
echo "Updating the package cache..."
31-
apt-get -qq update
31+
yum -q makecache
3232
fi
3333
}
3434

3535
_cleanup_package_cache() {
3636
if [ "${PACKAGE_TAG:-}" != "builtin" ]; then
3737
echo "Cleaning up the package cache..."
38-
rm -rf /var/lib/apt/lists/*
38+
yum clean all
3939
fi
4040
}
4141

@@ -47,8 +47,8 @@ _update_ca_certificates() {
4747

4848
# Resolve the kernel version to the form major.minor.patch-revision-flavor where flavor defaults to generic.
4949
_resolve_kernel_version() {
50-
local version=$(apt-cache show "linux-headers-${KERNEL_VERSION}" 2> /dev/null | \
51-
sed -nE 's/^Version:\s+(([0-9]+\.){2}[0-9]+)[-.]([0-9]+).*/\1-\3/p' | head -1)
50+
local version=$(yum info "kernel-headers-${KERNEL_VERSION}" 2> /dev/null | \
51+
grep Version | sed -nE 's/^Version\s+:\s+(([0-9]+\.){2}[0-9]+)[-.]([0-9]+).*/\1-\3/p' | head -1)
5252
local flavor=$(echo ${KERNEL_VERSION} | sed 's/[^a-z]*//' | grep -Ev "^generic|virtual")
5353

5454
echo "Resolving Linux kernel version..."
@@ -73,7 +73,7 @@ _install_prerequisites() (
7373
mkdir -p /lib/modules/${KERNEL_VERSION}/proc
7474

7575
echo "Installing Linux kernel headers..."
76-
apt-get -qq install --no-install-recommends linux-headers-${KERNEL_VERSION} > /dev/null
76+
yum install -y kernel-headers-${KERNEL_VERSION} > /dev/null
7777

7878
echo "Installing Linux kernel module files..."
7979
apt-get -qq download linux-image-${KERNEL_VERSION} && dpkg -x linux-image*.deb .

0 commit comments

Comments
 (0)