Skip to content

Commit

Permalink
upgrade to Ubuntu 22, b2sdk 2.x, add instructions to README
Browse files Browse the repository at this point in the history
  • Loading branch information
snarfed committed Jul 2, 2024
1 parent 7ca55d8 commit 611fd37
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 4 deletions.
18 changes: 17 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@ sudo chsh ubuntu
# install and set up huffduff-video
cd ~/src
git clone https://github.com/snarfed/huffduff-video.git
sudo pip3 install b2sdk webob yt-dlp
cd huffduff-video
sudo pip3 install -r requirements.txt

# add these lines to /etc/httpd/conf/httpd.conf
#
Expand Down Expand Up @@ -135,6 +136,21 @@ EOF
crontab crontab
```

### Upgrading OS

huffduff-video is pretty small and simple, it doesn't have many unusual dependencies or needs, so I've generally had good luck using Ubuntu's [`do-release-upgrade`](https://askubuntu.com/questions/409555/what-does-do-release-upgrade-really-do) tool to [upgrade from one Ubuntu LTS version to the next](https://ubuntu.com/server/docs/how-to-upgrade-your-release) ([more](https://help.ubuntu.com/community/Upgrades), [even more](https://help.ubuntu.com/community/UpgradeNotes)):

```sh
sudo apt-get update
sudo apt-get upgrade
sudo do-release-upgrade
```

Python installed packages may disappear, make sure to reinstall those with sudo! Otherwise Apache's mod_wsgi won't see them, or will see older versions.

```
sudo pip3 install -r requirements.txt
```

## SSL

Expand Down
7 changes: 4 additions & 3 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@
import sys
import urllib.parse

from b2sdk.account_info.in_memory import InMemoryAccountInfo
from b2sdk.api import B2Api
from b2sdk.progress import AbstractProgressListener
# https://github.com/Backblaze/b2-sdk-python/blob/master/CHANGELOG.md#changed-2
from b2sdk.v1 import InMemoryAccountInfo
from b2sdk.v1.api import B2Api
from b2sdk._internal.progress import AbstractProgressListener
import boto.ec2.cloudwatch
import requests
import webob
Expand Down
5 changes: 5 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
b2sdk==1.9.0

This comment has been minimized.

Copy link
@ascandroli

ascandroli Sep 7, 2024

Owner

working on updating the Dockerfile to match this upgrade I noticed that the b2sdk version is 1.9 even though the commit message says b2sdk 2.x.

boto==2.49.0
requests==2.32.3
WebOb==1.8.7
yt-dlp>=2024.5.27

0 comments on commit 611fd37

Please sign in to comment.