Tania is an open-source, free, and private farm management software application. It helps you manage your farm operations and track your production data. In this tutorial, you'll learn how to install Tania on NetBSD, a BSD operating system.
pkgin update
pkgin install nginx php73 php73-pdo_pgsql php73-fpm postgresql12-server tmux memcached
service postgresql onestart
tar -xvf tania-x.x.x.tar.gz
htdocs
directory of nginx webserver:mv tania-1.6.0 /usr/pkg/nginx/htdocs/tania
sudo -i -u postgres
createdb -E UTF8 tania_db
psql -c "CREATE USER tania_user WITH PASSWORD 'PASSWORD';"
psql -c "GRANT ALL PRIVILEGES ON DATABASE tania_db to tania_user;"
exit
cd /usr/pkg/nginx/htdocs/tania
cp .env.example .env
vi .env
DB_CONNECTION=pgsql
DB_HOST=127.0.0.1
DB_PORT=5432
DB_DATABASE=tania_db
DB_USERNAME=tania_user
DB_PASSWORD=PASSWORD
cd /usr/pkg/nginx/conf/conf.d
vi tania.conf
server {
listen 80;
server_name tania.example.com;
index index.php;
root /usr/pkg/nginx/htdocs/tania/public;
access_log /var/log/nginx/tania_access.log;
error_log /var/log/nginx/tania_error.log warn;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~* \.(gif|jpg|jpeg|png|svg|css|js|ico)$ {
expires max;
add_header Cache-Control "public, must-revalidate, proxy-revalidate";
try_files $uri /index.php?s=$uri&$args;
}
location ~ \.php$ {
fastcgi_pass unix:/var/run/php-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
include fastcgi_params;
}
}
Note: Replace tania.example.com
with your server's domain name or IP address.
service nginx restart
cd /usr/pkg/nginx/htdocs/tania
tmux new-session -s tania -d 'php -S 127.0.0.1:8080 -t public'
memcached -d -u root
http://tania.example.com
.Congratulations! You have successfully installed Tania on NetBSD. You can now start managing your farm operations and tracking your production data with Tania.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!