admin-scripts/pi2/justfile

31 lines
787 B
Makefile
Raw Normal View History

2024-06-20 17:12:41 +02:00
## Justfile (https://github.com/casey/just)
##
## Services:
## - archivebox
data_dir := "/nfs/archivebox"
nfs_mnt := "10.0.0.6:/mnt/coffeeNAS/archivebox"
run_user := env_var("USER")
default: env install
env:
sudo mkdir -p {{ data_dir }}
sudo chown -R {{ run_user }}:{{ run_user }} {{ data_dir }}
echo "{{ nfs_mnt }} {{ data_dir }} nfs4 soft,intr,rsize=8192,wsize=8192" | sudo tee -a /etc/fstab
sudo systemctl daemon-reload
sudo mount -av
install:
sudo apt install -y pipx python3-dev python3-pip nodejs npm curl wget git ripgrep
pipx install archivebox
pipx install yt-dlp
pipx install playwright
playwright install --with-deps chromium
init:
cd {{ data_dir }} && archivebox init --setup
setup:
cd {{ data_dir }} && archivebox setup