1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-03-09 15:40:17 +00:00

Merge pull request #3769 from holta/yt-dlp_upgrading

Strengthen Calibre-Web's yt-dlp upgrading + document yt-dlp "nightly" version
This commit is contained in:
A Holt 2024-07-18 03:22:37 -04:00 committed by GitHub
commit cca3cd2395
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 23 additions and 11 deletions

View file

@ -157,26 +157,31 @@ as it contains your Calibre-Web content **and** configuration settings!
Upgrading Upgrading
--------- ---------
"Reinstalling" Calibre-Web automatically installs the latest version — if your Please see our `new/automated upgrade technique (iiab-update) <https://github.com/iiab/calibre-web/wiki#upgrading>`_
Internet-in-a-Box (IIAB) is online. introduced in July 2024.
But first: back up your content **and** configuration settings, as explained above. But first: back up your content **and** configuration settings, as outlined
above!
**Also move your /library/calibre-web/config/app.db AND/OR **Conversely if you're sure you want to fully reset your Calibre-Web settings,
/library/calibre-web/metadata.db out of the way — if you're sure you want to and remove all existing e-book/video/media metadata — then move your
fully reset your Calibre-Web settings (to install defaults) AND/OR remove all /library/calibre-web/config/app.db, /library/calibre-web/metadata.db and
e-book metadata! Then run, as root**:: /library/calibre-web/xklb-metadata.db out of the way.**
RECAP: Either way, "reinstalling" Calibre-Web automatically installs the latest
version — so long as your Internet-in-a-Box (IIAB) is online. Most people
should stick with the new ``iiab-update`` technique above. However if you must
use the older/manual approach, you would need to run, as root::
cd /opt/iiab/iiab cd /opt/iiab/iiab
./runrole --reinstall calibre-web ./runrole --reinstall calibre-web
Or, if you just want to upgrade Calibre-Web code alone, prior to proceeding Or, if there's a need to try updating Calibre-Web's code alone::
manually::
cd /usr/local/calibre-web-py3 cd /usr/local/calibre-web-py3
git pull git pull
This older way is *no longer recommended*:: Finally, this much older way is *no longer recommended*::
cd /opt/iiab/iiab cd /opt/iiab/iiab
./iiab-install --reinstall # OR: ./iiab-configure ./iiab-install --reinstall # OR: ./iiab-configure

View file

@ -1,3 +1,8 @@
# To upgrade IIAB Calibre-Web:
# https://github.com/iiab/calibre-web/wiki#upgrading
# https://github.com/iiab/iiab/blob/master/scripts/iiab-update
- name: Record (initial) disk space used - name: Record (initial) disk space used
shell: df -B1 --output=used / | tail -1 shell: df -B1 --output=used / | tail -1
register: df1 register: df1
@ -70,7 +75,7 @@
if [ -f {{ calibreweb_venv_path }}/scripts/lb-wrapper ]; then if [ -f {{ calibreweb_venv_path }}/scripts/lb-wrapper ]; then
apt install ffmpeg pipx -y apt install ffmpeg pipx -y
if lb --version; then if lb --version; then
pipx upgrade --include-injected xklb pipx reinstall xklb
else else
pipx install xklb pipx install xklb
ln -sf /root/.local/bin/lb /usr/local/bin/lb ln -sf /root/.local/bin/lb /usr/local/bin/lb
@ -82,6 +87,8 @@
echo "ERROR: yt-dlp NOT FOUND" echo "ERROR: yt-dlp NOT FOUND"
fi fi
fi fi
# IF YOU WANT THE "nightly" RELEASE OF yt-dlp, UNCOMMENT THE NEXT LINE:
# pipx inject --pip-args="--upgrade --pre" -f xklb yt-dlp[default]
cp {{ calibreweb_venv_path }}/scripts/lb-wrapper /usr/local/bin/ cp {{ calibreweb_venv_path }}/scripts/lb-wrapper /usr/local/bin/
chmod a+x /usr/local/bin/lb-wrapper chmod a+x /usr/local/bin/lb-wrapper
fi fi