Skip to content

Instantly share code, notes, and snippets.

@santaklouse
santaklouse / README.md
Last active November 2, 2026 22:42
Automated deployment of a VLESS + WebSocket proxy on Linux using sing-box and localhost.run SSH tunneling. Designed for restricted environments and cloud playgrounds without public IP addresses or direct inbound port access.

VLESS Server — Automated Deployment

Deploy a VLESS + WebSocket proxy on Linux using sing-box, Docker, and Cloudflare Quick Tunnels.

This project is intended for temporary Linux VMs, cloud playgrounds, and restricted environments where direct inbound connections or a public IP address are unavailable.

Features

  • Automated sing-box deployment with Docker.
  • VLESS protocol with WebSocket transport.
@santaklouse
santaklouse / README.md
Created October 3, 2026 11:00
MacOS: Remove local time machine snapshots

MacOS: Remove local time machine snapshots

List snapshots

tmutil listlocalsnapshots /

Remove all local snapshots

sudo tmutil deletelocalsnapshots /
@santaklouse
santaklouse / Makefile
Created September 9, 2026 10:05
Makefile for automated PostgreSQL Docker backups (pg_dump)
CONTAINER_NAME=defguard-db-1
DB_USER=defguard
BACKUP_DIR=.
BACKUP_DAYS=7
.PHONY: backup-db restore-db check-container clean-old-backups
# Вспомогательное правило: проверка, запущен ли контейнер
check-container:
@docker ps --filter "name=$(CONTAINER_NAME)" --filter "status=running" --format "{{.Names}}" | grep -q "^$(CONTAINER_NAME)$$" || \
@santaklouse
santaklouse / README.md
Last active August 13, 2026 10:14
Ubuntu VPS Disk Space Monitor & Auto-Cleanup Script

Ubuntu VPS Disk Space Monitor & Auto-Cleanup Script

A lightweight Bash script designed for Ubuntu VPS to monitor disk space hourly. If disk usage exceeds the defined threshold, it automatically triggers Docker cache eviction, removes stopped containers, rotates system logs, and sends instant status alerts directly to Telegram.

Features

  • Proactive Monitoring: Runs quietly every hour via cron.
  • Telegram Alerts: Sends instant notifications using your custom tg_say utility.
  • Docker Optimization: Seamlessly calls your user-defined ~/.bashrc aliases (docker_clean_cache, docker_clean_exited) under the ubuntu user scope.
  • Log Rotation: Safely vacuums journald logs down to 50MB and removes archived log files (*.gz, *.1) from /var/log.
@santaklouse
santaklouse / sshfs.mount.sh
Created August 5, 2026 16:54
mount/umount scripts for mac sshfs
#!/usr/bin/env bash
sshfs vps2:/home/ubuntu/tmp /Users/alexnevpryaga/sshfs-mount/
@santaklouse
santaklouse / update_macos.sh
Created August 5, 2026 16:43
Update macos to specific version
#!/usr/bin/env bash
softwareupdate --fetch-full-installer --agree-to-license --install --all
@santaklouse
santaklouse / publish_port.sh
Created July 31, 2026 21:08
Share port to internet using free service http://localhost.run/
#!/bin/bash
publish_to_internet_https() {
PORT="${1:-8080}"
echo "Open port ${PORT} to internet https..."
sleep 2
echo -n "Your public domains: "
ssh -R 80:localhost:${PORT} localhost.run 2>&1 | grep 'tunneled with tls termination'
}
@santaklouse
santaklouse / stealth_loader.py
Last active June 21, 2026 04:51
Win64 stagers testing
import ctypes
import sys
import struct
import zlib
import tempfile
import os
if sys.platform != "win32":
print("[-] This script works only on Windows")
sys.exit(1)
@santaklouse
santaklouse / README.md
Created June 7, 2026 00:04
Bash script to minify and heavily obfuscate JavaScript files using Terser and javascript-obfuscator.
@santaklouse
santaklouse / add_playerjs_chromecast.cjs
Created June 3, 2026 14:30
It takes PlayerJS without Chromecast (pro module), removes the external Dean Edwards Packer layer if necessary inserts the ChromeCast module and adds a button with linkurl:"chromecast" to the skin/template.
#!/usr/bin/env node
'use strict';
/**
* add_playerjs_chromecast.cjs
*
* Uses PlayerJS without Chromecast, removes the external Dean Edwards Packer layer if necessary,
* inserts the ChromeCast module and adds a button with linkurl:"chromecast" to the skin/template.
*
* Usage: