Install wkhtmltopdf on Debian 11

1. Install prerequisites: Install wget (if not already installed):

# sudo apt update
# sudo apt install wget

2. Install wkhtmltopdf on Debian 11

The links below contain the latest releases as of 10/25/2022. Please double check GitHub for the latest available release: https://github.com/wkhtmltopdf/packaging/releases/latest

# wget https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6.1-2/wkhtmltox_0.12.6.1-2.bullseye_amd64.deb
# sudo apt install ./wkhtmltox*bullseye_amd64.deb

Check that the version installed is what you were expecting:

# wkhtmltopdf --version
wkhtmltopdf 0.12.6.1 (with patched qt)
Share

Install and Setup TIG Stack on Ubuntu 20.04

In this tutorial, we are going to learn how to install and setup TIG Stack on Ubuntu 20.04.

TIG stack is a group of powerful open-source monitoring tools, Telegraf, InfluxDB and Grafana where;

  • Telegraf is an open-source server agent for collecting and sending metrics and events from databases, systems, and IoT sensors.
  • InfluxDB is an open-source time series database and provides datastore for metrics, events, and real-time analytics.
  • Grafana is a data visualization and monitoring tool and supports time series datastores such as Graphite, InfluxDB, Prometheus, Elasticsearch.

TIG stack can be used for monitoring system metrics such as memory, disk, logged in users, system load, swap usage, system uptime, system processes. 

Installing and Setup TIG Stack on Ubuntu 20.04

In order to install TIG stack, you need to install and setup each individual component of the stack, Telegraf, InfluxDB, Grafana.

Run System Update
To begin with, ensure that your system packages are up-to-date;

apt update
apt upgrade

Install Telegraf on Ubuntu 20.04

You can install Telegraf on Ubuntu 20.04 either by downloading the DEB package file or directly from the InfluxData repos.

Install Telegraf using DEB Package File

To install Telegraf using the DEB binary, grab the binary installer from the InfluxData downloads page. You can simply obtain the link to binary installer and pull it with wget;

wget https://dl.influxdata.com/telegraf/releases/telegraf_1.14.3-1_amd64.deb

Once you have the binary downloaded, you can install it as follows

Read more

Share

WordPress WP Backup Sample Script

#!/bin/bash

# your backups will use these filenames.
db_backup_name=”tweenpath-db-backup-“`date “+%Y-%m-%d”`”.sql.gz”
wpfiles_backup_name=”tweenpath-files-backup-“`date “+%Y-%m-%d”`”.tar.gz”

## 1: database connection info. You can get these details from your wp-config file.
db_name="user_name"
db_username="database"
db_password="password"

## 2: Path to your WordPress Upload and Theme directories. Replace /home/username/ with path to your home directory.
wp_upload_folder="/home/tweenpath/public_html"

## 3: Path to your backup folder. Replace /home/username/ with path to your home directory.
backup_folder_path="/backup/tweenpath"

# backup MYSQL database, gzip it and send to backup folder.
mysqldump --opt -u$db_username -p$db_password $db_name | gzip > $backup_folder_path/$db_backup_name

# create a tarball of the wordpress files, gzip it and send to backup folder.
tar -czf $backup_folder_path/$wpfiles_backup_name $wp_upload_folder|

# delete all but 5 recent wordpress database back-ups (files having .sql.gz extension) in backup folder.
find $backup_folder_path -maxdepth 1 -name "*.sql.gz" -type f | xargs -x ls -t | awk 'NR>5' | xargs -L1 rm

# delete all but 5 recent wordpress files back-ups (files having .tar.gz extension) in backup folder.
find $backup_folder_path -maxdepth 1 -name "*.tar.gz" -type f | xargs -x ls -t | awk 'NR>5' | xargs -L1 rm

Src and Ref:

Auto BackUp WordPress Files Using a Simple Bash Script

Share

Setup Apache, FastCGI and PHP 7.4 on Ubuntu 20

Prerequisites

Update the installed packages.

apt update

Install the Ondřej PHP repository.

apt install software-properties-commonsudo
add-apt-repository ppa:ondrej/php
apt update

Check that the repositories are correctly installed.

grep ^ /etc/apt/sources.list /etc/apt/sources.list.d/*

Step 1 – Install Apache

apt install apache2

Read more

Share

Installation of Collabora on Debain 12

Collabora CODE is more straightforward to install than Nextcloud. Typically, Collabora prerequisites are installed when Nextcloud is installed. To install Collabora CODE, follow the steps below:

Import the Collabora CODE signing key.

cd /usr/share/keyrings
sudo wget https://collaboraoffice.com/downloads/gpg/collaboraonline-release-keyring.gpg

Create a source file for the Collabora CODE package repository.

sudo vi /etc/apt/sources.list.d/collaboraonline.sources

Add the following information to the file and save it.

nano /etc/apt/sources.list.d/collaboraonline.sources
Types: deb
URIs: https://www.collaboraoffice.com/repos/CollaboraOnline/CODE-ubuntu2204
Suites: ./
Signed-By: /usr/share/keyrings/collaboraonline-release-keyring.gpg

Update the repository

Read more

Share

Installing Plex on Debian 12

Prerequisites

  • A machine running Debian 12 with GUI mode
  • A user account with sudo privileges
  • Internet access for downloading packages

Step 1: Update Your System

Before installing any new software, it’s always a good practice to update your system’s package index. Open a terminal and execute the following command:

sudo apt update && sudo apt upgrade -y

Step 2: Install Required Dependencies

Next, install the necessary dependencies for Plex Media Server:

sudo apt install curl gnupg2 -y

Step 3: Add Plex Repository

To ensure you’re installing the latest version of Plex, add the official Plex repository to your system:

echo deb https://downloads.plex.tv/repo/deb public main | sudo tee /etc/apt/sources.list.d/plexmediaserver.list

Then, add the Plex GPG key:

curl https://downloads.plex.tv/plex-keys/PlexSign.key | sudo apt-key add -

Step 4: Install Plex Media Server

Update your package index again and install Plex Media Server:

sudo apt update
sudo apt install plexmediaserver -y

Step 5: Enable and Start Plex Service

Once installed, enable Plex to start on boot and then start the service:

sudo systemctl enable plexmediaserver
sudo systemctl start plexmediaserver

Step 6: Configure Plex Media Server

Access the Plex web interface by navigating to

http://localhost:32400/web

from a browser on GUI console using your preferred web browser. From there, you can create your Plex account or sign in, and follow the on-screen instructions to configure your media library.

Share

Install PHPIPAM using Docker on CentOS 7

Update Docker Package Database. In a terminal window, type:

sudo yum check-update

Remove if any docker is preinstalled with your OS-

sudo yum remove docker docker-client docker-client-latest docker-common docker-latest docker-latest-logrotate docker-logrotate docker-selinux docker-engine-selinux docker-engine

Install the Dependencies

sudo yum install -y yum-utils device-mapper-persistent-data lvm2

The –y switch indicates to the yum installer to answer “yes” to any prompts that may come up. The yum-utils switch adds the yum-config-manager. Docker uses a device mapper storage driver, and the device-mapper-persistent-data and lvm2 packages are required for it to run correctly.

Read more

Share

Install Jitsi on Debian 11

This article will go through the installation and configuration of the Jitsi Video Conference on the latest Debian 11 Bullseye. At the end of this guide, you will be able to create a meeting using the Jitsi Video conference.

Before you get started, ensure you’ve got the following requirements:

  • Operating System: Debian 11 Bullseye
  • Root privileges

Install Packages Dependencies

The first step is to install some packages dependencies such as gnupg2, nginx-full, sudo, apt-transport-https, curl, and java OpenJDK.

1. Update your Debian repository and install those packages on top using the following command.

sudo apt install apt-transport-https gnupg2 nginx-full sudo curl -y

2. Jitsi required Java OpenJDK version 1.8 or 1.11; the default Debian repository provides Java OpenJDK 1.11.

Now execute the following command to install Java OpenJDK packages.

sudo apt install default-jdk -y

After installation completes, verify the Java OpenJDK version using the following command.

java -version

You will see a similar output as below.

openjdk version "11.0.13" 2021-10-19
OpenJDK Runtime Environment (build 11.0.13+8-post-Debian-1deb11u1)
OpenJDK 64-Bit Server VM (build 11.0.13+8-post-Debian-1deb11u1, mixed mode, sharing)

After all packages have been installed, move on to setting up Jitsi and Prosody repositories.

Read more

Share

Nextcloud Upgrade Issue via Web

My Nextcloud update via web was constantly failing. So looked for alternate CLI methods.

Method#1 Using occ cli

sudo -u www-data php ./occ upgrade
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
Set log level to debug
Updating database schema
Updated database
Updating <files_pdfviewer> ...
Updated <files_pdfviewer> to 1.1.1
Updating <gallery> ...
Updated <gallery> to 17.0.0
Updating <activity> ...
Updated <activity> to 2.5.2
Updating <comments> ...
Updated <comments> to 1.2.0
Updating <theming> ...
Updated <theming> to 1.3.0
Starting code integrity check...
Finished code integrity check
Update successful
Maintenance mode is kept active
Reset log level

Method#1 Using updater.phar

Read more

Share