Skip to content

Instantly share code, notes, and snippets.

@hunzo
hunzo / fix-fonts.sh
Last active October 15, 2025 02:42
fix ubuntu-22.04 thai fonts
#!/bin/bash
# Fix Thai font rendering and replace common fonts (Segoe UI, Arial, etc.) with Noto Sans Thai/Noto Sans
set -euo pipefail
echo "[*] Installing fonts (if available)..."
if command -v apt >/dev/null 2>&1; then
sudo apt update
sudo apt install -y fonts-noto-core fonts-noto-color-emoji fonts-noto-mono || true
fi
@hunzo
hunzo / readme.md
Last active October 14, 2025 03:07
Set Ptyxis transparent

Set Ptyxis transparent

dconf read /org/gnome/Ptyxis/default-profile-uuid
gsettings get org.gnome.Ptyxis.Profile:/org/gnome/Ptyxis/Profiles/8fadbd21282f5af820285e8168ebd543/ opacity
gsettings set org.gnome.Ptyxis.Profile:/org/gnome/Ptyxis/Profiles/8fadbd21282f5af820285e8168ebd543/ opacity 0.95
@hunzo
hunzo / install.sh
Created October 7, 2025 06:28
remmina install
#!/bin/bash
sudo apt autoremove -y
sudo apt-add-repository ppa:remmina-ppa-team/remmina-next
sudo apt update -y
sudo apt install remmina remmina-plugin-rdp remmina-plugin-secret -y
@hunzo
hunzo / vpnc-setup.sh
Last active September 30, 2025 08:44
#!/bin/bash
echo "Initializing VPN setup script..."
echo "enter vpn server:"
read vpnserver
echo "enter vpn user:"
read vpnuser
@hunzo
hunzo / fix-all.sh
Last active October 14, 2025 03:25
create file /etc/fonts/conf.d/99-segoe-ui-alias.conf
#!/bin/bash
CONF_FILE_1="/etc/fonts/conf.d/99-fix-all-thai.conf"
sudo tee "$CONF_FILE_1" >/dev/null <<'EOF'
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<alias>
<family>Arial</family>
@hunzo
hunzo / example-policy.json
Last active August 21, 2025 07:00
Minio Client
{
"Version": "2012-10-17",
"Statement": [
{
"Action": ["s3:GetBucketLocation", "s3:ListBucket"],
"Effect": "Allow",
"Resource": ["arn:aws:s3:::mybucket"]
},
{
"Action": ["s3:PutObject", "s3:GetObject", "s3:DeleteObject"],
@hunzo
hunzo / ceph-mon-fix.md
Created August 21, 2025 01:57
fix ceph-mon start error

ceph-mon start error

Check process

ps -ef | grep ceph-mon
netstat -tulnp | grep 6789
  • if exist kill process
@hunzo
hunzo / convert-vmdk-to-qcow2.sh
Last active August 19, 2025 03:18
bash script convert vmdk to qcow2
#!/bin/bash
# convert-vmdk-to-qcow2.sh
for vmdk in *.vmdk; do
if [[ -f "$vmdk" ]]; then
qcow2="${vmdk%.vmdk}.qcow2"
echo "Converting $vmdk -> $qcow2"
qemu-img convert -f vmdk -O qcow2 "$vmdk" "$qcow2"
fi
done
@hunzo
hunzo / kali.sh
Created August 4, 2025 09:13
kali tool scan
#!/bin/bash
# Define container name (optional)
CONTAINER_NAME=kali-nuclei-wpscan
# Run Kali container with interactive shell
docker run -it --rm -v .:/docs --name $CONTAINER_NAME kalilinux/kali-rolling /bin/bash -c "
echo '[+] Updating packages...' && \
apt update -y && apt install -y nuclei wpscan && apt install pandoc -y && apt install jq -y && \
echo '[✓] Installation complete.' && \
@hunzo
hunzo / compose.yaml
Created August 4, 2025 01:52
docker n8n with reverse proxy
services:
n8n:
image: n8nio/n8n
restart: unless-stopped
ports:
- 5678:5678
environment:
- N8N_BASIC_AUTH_ACTIVE=true
- N8N_BASIC_AUTH_USER=your_admin_user
- N8N_BASIC_AUTH_PASSWORD=your_admin_password