I recently got into self-hosting. I've wanted to create a self-hosted web archive and my friend recommended an Archivebox, unfortunately TrueCharts doesn't have a chart for it so I had to do it myself. Here's my guide on how to setup Archivebox on Truenas Scale.
First of all you to setup an Archivebox user. As Archivebox container won't even start as root. Go to Credentials -> Local Users -> Add. Create a new user with a username
archivebox and toggle
To setup Archivebox I you need to use
custom-app chart from TrueCharts repository.
Change Application name to
Archivebox. Then set_Container Image -> Container Repository_ to
archivebox/archivebox, Container Tag to
latest and Container Pullpolicy to
Enable All liveness probes.
Then set Networking and Services -> Main Service Port Configuration, Port type to
HTTP, Target Port to
8000 and Port to some random port number like
Service type will depend on your setup.
Last of all, the storage. You need to mount 2 paths:
For your connivance I recommend to mount
/data as hostPath and
/var/spool/cron/crontabs as PVC. As
/data requires some setup later.
Update: After using this setup I found that mountung
/var/spool/cron/crontabsdoesn't work as expected - the files are erased and jobs stop.
Set Pod Security Context -> fsGroup to group id of group
Then click Save.
Go to System setting -> Shell and cd into
docker run -v $PWD:/data -it archivebox/archivebox init --setup
It will setup Archivebox db. After this step, you should be able to access the webui.
If you cannot do that, make sure, that HostPath directory has correct permissions.
chown archivebox:archivebox YOUR_DIR
I've noticed that some of my scheduled runs were failing. To fix them i run these commands inside the container.
Change the owner of
chown -R archivebox:archivebox /var/spool/cron/crontabs
Then change the user to archivebox.
su - archivebox
/data and run:
archivebox init --setup