acytoo

Linux Caddy Mariadb PHP Wordpress LCMP

Configure LCMP stack

LCMP refers to Linux-Caddy-MariaDB-PHP

Where M can also be Mysql


Been using caddy + hugo for 2 years. Though there are developed cmi(content management system) like netlifycms for hugo, it's inconvenient to post new contents, so I decided to give wordpress a try. I already tried nginx and apache before, and found them pretty difficult to configure. So I will stick with caddy as backend.

Reverse Visual Search

Back in the 1990s, when the Internet was still a young baby, the speed of the Internet was slow, and the capacity of the Internet was small. The main content on the Internet is text, so the search engines invented that time can search texts, and those search engines work really well on text. But the internet has developed really fast in the last 10 years, new technology makes it faster and stronger, people are surrounded by images and videos(visual information), how we can index images and search them is the new challenge. Some search engines like Google can search images, and we are interested in how they can search using images, so we did some research in the reverse visual search field.

Database Postgresql Query Metadata

Display all the information schema views supported by PostgreSQL and which we can use for retrieving database meta information for current database

SELECT * 
FROM information_schema.views 
WHERE table_schema = 'information_schema' 
ORDER BY table_name;

To retrieve name of the current database, this will list all tables within database, both user defined and postgresql defined. Basically all information we need is stored in those table, try to select * from them and see.

2D Kalman Filter Multiple Object Tracking

Some times we have following cases

  1. Where the variable of interest can only be measured indirectly.
  2. Measurements are available from various sensors but might be subject to noise.

We can use Kalman Filter for those cases, but remember, general Kalman Filter works well for objects/measurements changing at constant velocity or constant acceleration.

Linux Caddy Postgresql PHP - LCPP

Linux Caddy Postgresql PHP

Installation

Linux

Debian 11

Caddy
sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list
sudo apt update
sudo apt install caddy
PHP
sudo apt update && sudo apt full-upgrade -y
sudo apt install php php-fpm php-cli php-gd -y
Postgresql
sudo apt install postgresql php-pgsql -y

Configuration

Caddy
sudo nano /etc/caddy/Caddyfile
php.acytoo.com {
	root * /var/www/php.acytoo.com
	log {
		output file /var/log/caddy/php.acytoo.com.log
	}
	encode gzip
	php_fastcgi unix//run/php/php7.4-fpm.sock
}

If you want to uer file_server along with php, please check file_server vs php