This message was deleted.
# general
a
This message was deleted.
c
method conflict?
you can get the tarballs from github for any given version; are you specifying the version when installing so that you can match the RPM to the tarballs?
m
method conflict: https://github.com/rancher/rke2/blob/master/install.sh#L137 But the yum repos setup in the script point to repos that you need internet connectivity for
this doesnt seem to work (maybe I’m doing something wrong): https://github.com/rancher/rke2/blob/master/install.sh#L579
this works: https://github.com/rancher/rke2/blob/master/install.sh#L577, but its kind of buried on how to construct these env variables to pick up the version correctly
c
Why are you installing tars on top of RPMs?
m
so we end up just forking the install script, removing
check_method
conflict, and doing
Copy code
rke2_rpm_version=$(echo "${INSTALL_RKE2_VERSION}" | sed -E -e "s/[\+-]/~/g" | sed -E -e "s/v(.*)/\1/")
yum install -y rke2-server-${rke2_rpm_version}~rke2r1-0.el8.x86_64
this seems like the wrong way we should be doing things
c
yeah I’m really confused by what you’re doing here
m
yeah 😓 thats why I’m coming here for help
is there a different way we can load images without doing
INSTALL_RKE2_ARTIFACT_PATH=/root/rke2-artifacts sh install.sh
c
try with
INSTALL_RKE2_METHOD=rpm INSTALL_RKE2_VERSION=v1.25.12+rke2r1 INSTALL_RKE2_ARTIFACT_PATH=/where/you/put/stuff
although that might not work exactly right, I’m not sure that handles the RPM stuff correctly.
The error you were getting indicates that you previously installed from tarballs, so make sure you don’t have any of that left behind when running it
I mean, if you’re doing RPMs you can just install them normally, and place the images in /var/lib/rancher/rke2/agent/images yourself
with RPMs, that’s really all the install script is doing for you - since you don’t need it to go out and grab stuff from GH for you
the install script doesn’t add much value if you already know which version you want, and have all the files downloaded
m
yeah but we need some of the other configuration that’s done in install.sh, such as https://github.com/rancher/rke2/blob/master/install.sh#L625
c
is that it? you just need the fapolicy rules, and the tarballs copied over?
m
yeah I tried this
INSTALL_RKE2_METHOD=rpm INSTALL_RKE2_VERSION=v1.25.12+rke2r1 INSTALL_RKE2_ARTIFACT_PATH=/where/you/put/stuff,
but it wont handle the rpms in air gapped unfortunately, because they’re pointing to the upstream rke2 yum repo: https://github.com/rancher/rke2/blob/master/install.sh#L537
we have to do a reposync on those, and bring them in
is that it? you just need the fapolicy rules, and the tarballs copied over?
I think so? not sure what else the installer does that we might need. if we dont need it, then we can copy paste the fapolicyd stuff
c
Yeah, I think your best bet is just to handle it yourself