Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix nightly tests #7630

Merged
merged 2 commits into from
Jan 28, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions tests/install/centos-9/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,4 @@ Vagrant.configure("2") do |config|
SHELL
end

config.vm.provision "selinux-status", type: "shell", run: "once", inline: "sestatus -v"
config.vm.provision "rke2-profile-env", type: "shell", run: "once" do |sh|
sh.inline = <<~SHELL
#!/usr/bin/env bash
cat <<-EOF > /etc/profile.d/rke2.sh
export KUBECONFIG=/etc/rancher/rke2/rke2.yaml PATH=/usr/local/bin:$PATH:/var/lib/rancher/rke2/bin
EOF
SHELL
end

end
3 changes: 2 additions & 1 deletion tests/install/install_util.rb
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,8 @@ def runKillAllScript(vm)
#!/usr/bin/env bash
set -eu -o pipefail
echo 'Run kill all'
/usr/local/bin/rke2-killall.sh
# This script runs as sudo, which may not have the PATH set correctly.
PATH=/usr/local/bin:$PATH rke2-killall.sh
SHELL
end
end
2 changes: 2 additions & 0 deletions tests/install/opensuse-leap/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ Vagrant.configure("2") do |config|
config.vm.define "install-leap-15.6", primary: true do |test|
test.vm.hostname = 'smoke'
test.vm.provision 'rke2-upload-installer', type: 'file', run: 'always', source: ENV['TEST_INSTALL_SH'], destination: 'install.sh'
# Leap 15.6+ VM images are missing procps for some reason.
test.vm.provision 'rke2-prepare', type: 'shell', run: 'once', inline: 'zypper install -y apparmor-parser procps'
test.vm.provision"rke2-install", type: 'rke2', run: "once" do |rke2|
rke2.installer_url = 'file:///home/vagrant/install.sh'
rke2.env = %W[ #{external_env} INSTALL_RKE2_TYPE=server]
Expand Down
11 changes: 1 addition & 10 deletions tests/install/rocky-8/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ Vagrant.configure("2") do |config|
config.vm.define "install-rocky-8", primary: true do |test|
test.vm.hostname = 'smoke'
test.vm.provision "disable-firewall", type: "shell", inline: "systemctl stop firewalld"
test.vm.provision "add-bin-path", type: "shell", inline: "echo \"export PATH=/usr/local/bin:\$PATH\" >> ~/.bashrc"
test.vm.provision 'rke2-upload-installer', type: 'file', run: 'always', source: ENV['TEST_INSTALL_SH'], destination: 'install.sh'
test.vm.provision"rke2-install", type: 'rke2', run: "once" do |rke2|
rke2.installer_url = 'file:///home/vagrant/install.sh'
Expand Down Expand Up @@ -66,14 +67,4 @@ Vagrant.configure("2") do |config|
SHELL
end

config.vm.provision "selinux-status", type: "shell", run: "once", inline: "sestatus -v"
config.vm.provision "rke2-profile-env", type: "shell", run: "once" do |sh|
sh.inline = <<~SHELL
#!/usr/bin/env bash
cat <<-EOF > /etc/profile.d/rke2.sh
export KUBECONFIG=/etc/rancher/rke2/rke2.yaml PATH=/usr/local/bin:$PATH:/var/lib/rancher/rke2/bin
EOF
SHELL
end

end
Loading