Can't install package via script?
Waveterm isn't in Fedora repos, doesn't have a flatpak, etc, but they do release an rpm file. So I made a script that
grep
s the URL and rpm-ostree install
s the latest rpm package. Logs say:
[14:09:18 g.i/k/charoite:latest] => #32 12.46 Installing 1 packages:
[14:09:18 g.i/k/charoite:latest] => #32 12.46 waveterm-0.8.11-1.x86_64 (@commandline)
[14:09:18 g.i/k/charoite:latest] => #32 13.38 Installing: waveterm-0.8.11-1.x86_64 (local)
And no errors, the image builds fine, but the application is nowhere to be seen when updating.Solution:Jump to solution
I've had this issue with other rpms that install to /opt. If that's the case, you need to use the optfix option in your recipe. You'll likely also need to modify the .desktop file so it appears in your menu.
Here's how I do it with enpass which installs to /opt/enpass/...:
In my recipe under the rpm-ostree module, I add:...
8 Replies
https://github.com/kityr/charoite
my repo with the script and recipe and whatever (i commented out the script for now)
GitHub
GitHub - kityr/charoite: This is my OS based on silverblue-nvidia b...
This is my OS based on silverblue-nvidia by ublue. - kityr/charoite
Solution
I've had this issue with other rpms that install to /opt. If that's the case, you need to use the optfix option in your recipe. You'll likely also need to modify the .desktop file so it appears in your menu.
Here's how I do it with enpass which installs to /opt/enpass/...:
In my recipe under the rpm-ostree module, I add:
I then add a finalize-enpass-install.sh script to modify the enpass.desktop file with:
ohh, i see
Thanks!
haha wonder if optfix will fix the installation if it's not via the rpm-ostree module but by a script
I believe the rpm-ostree module was updated so that you can install directly from a url. Just put the url to the .rpm in the 'install' section.
Yes, but they don't have a permanent url for the latest package
I have a script that gets it though, let's see if i can $(substitute) it in the recipe
cuz i do have a script that echoes the url
So maybe i can
install:
- $(files/scripts/waveterm.sh)
doesnt seem to have crashed yet
yep doesnt work that way
cant have a file downloaded into files/ regularly either
lmao, i can make a github action to clone my repo, change the recipe with the url, and commit the change
although that is a bit too much jank
Yeah the url install path is meant for exact urls. We do allow using
%OS_VERSION%
in the url though
I have several scripts setup for my image to pull the latest release of some programs from github since they aren't in the default reposI would try using the optfix option, and making sure your script runs after the rpm-ostree module. Based on my experience, I think optfix simply makes the necessary directories and symlinks allowing the install to proceed correctly, but I'm not one of the devs so can't be certain.
This is pretty much exactly that