Skip to content

Commit

Permalink
Update to use metapkg and distro-specific repo. (#91)
Browse files Browse the repository at this point in the history
Promote go versions to 1.19.
Increase initial CSI startup timeout.
Remove old check.
  • Loading branch information
joe-atzinger authored Feb 1, 2023
1 parent d8a424a commit e04a9ef
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 21 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.18
go-version: ^1.19
id: go

- name: Checkout repository
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/darwin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.17
go-version: ^1.19
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/external_e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.17
go-version: ^1.19
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration_test_aks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.17
go-version: ^1.19
id: go
- name: Check out code
uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linux.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.17
go-version: ^1.19
id: go

- name: Check out code into the Go module directory
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sanity_test_local.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.17
go-version: ^1.19
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion deploy/csi-azurelustre-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ spec:
httpGet:
path: /healthz
port: healthz
initialDelaySeconds: 30
initialDelaySeconds: 60
timeoutSeconds: 10
periodSeconds: 30
env:
Expand Down
2 changes: 1 addition & 1 deletion deploy/csi-azurelustre-node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ spec:
httpGet:
path: /healthz
port: healthz
initialDelaySeconds: 30
initialDelaySeconds: 60
timeoutSeconds: 10
periodSeconds: 30
env:
Expand Down
24 changes: 11 additions & 13 deletions pkg/azurelustreplugin/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ echo "installClientPackages: ${installClientPackages}"
requiredLustreVersion=${LUSTRE_VERSION:-"2.15.1"}
echo "requiredLustreVersion: ${requiredLustreVersion}"

pkgVersion="${requiredLustreVersion}-24-gbaa21ca"
echo "pkgVersion: ${pkgVersion}"

pkgName="amlfs-lustre-client-${pkgVersion}"
echo "pkgName: ${pkgName}"

if [[ ! -z $(grep -R 'bionic' /etc/host-os-release) ]]; then
osReleaseCodeName="bionic"
elif [[ ! -z $(grep -R 'jammy' /etc/host-os-release) ]]; then
Expand All @@ -45,7 +51,7 @@ deb http://azure.archive.ubuntu.com/ubuntu/ jammy-security main restricted
deb http://azure.archive.ubuntu.com/ubuntu/ jammy-security universe
deb http://azure.archive.ubuntu.com/ubuntu/ jammy-security multiverse
EOF

osReleaseCodeName="jammy"
else
echo "Unsupported Linux distro"
Expand All @@ -56,27 +62,19 @@ echo "$(date -u) Command line arguments: $@"

if [[ "${installClientPackages}" == "yes" ]]; then
kernelVersion=$(uname -r)

echo "$(date -u) Installing Lustre client packages for OS=${osReleaseCodeName}, kernel=${kernelVersion} "

curl -sL https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor | tee /etc/apt/trusted.gpg.d/microsoft.gpg > /dev/null
echo "deb [arch=amd64] https://packages.microsoft.com/repos/amlfs/ ${osReleaseCodeName} main" | tee /etc/apt/sources.list.d/amlfs.list
echo "deb [arch=amd64] https://packages.microsoft.com/repos/amlfs-${osReleaseCodeName}/ ${osReleaseCodeName} main" | tee /etc/apt/sources.list.d/amlfs.list
apt-get update

# Install Lustre client module
lustreClientModulePackageVersion=$(apt list -a lustre-client-modules-${kernelVersion} | awk '{print $2}' | grep ^${requiredLustreVersion} | sort -u -V | tail -n 1 || true)

if [[ -z $lustreClientModulePackageVersion ]]; then
echo "can't find package lustre-client-modules-${kernelVersion} for Lustre version $requiredLustreVersion in Microsoft Linux Repo, exiting"
exit 1
fi

echo "$(date -u) Installing Lustre client modules: lustre-client-modules-${kernelVersion}=$lustreClientModulePackageVersion"
echo "$(date -u) Installing Lustre client modules: ${pkgName}=${kernelVersion}"

# grub issue
# https://stackoverflow.com/questions/40748363/virtual-machine-apt-get-grub-issue/40751712
DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends -o DPkg::options::="--force-confdef" -o DPkg::options::="--force-confold" \
lustre-client-modules-${kernelVersion}=$lustreClientModulePackageVersion
${pkgName}=${kernelVersion}

echo "$(date -u) Installed Lustre client packages."

Expand Down

0 comments on commit e04a9ef

Please sign in to comment.