Skip to content

Instantly share code, notes, and snippets.

@amircloner
amircloner / k8s-prepare-node.sh
Created August 27, 2024 09:38 — forked from hossainemruz/k8s-prepare-node.sh
Bash script to automatically install and configure container runtime, cni plugins etc
#!/bin/bash
set -eou pipefail
#========== Step 1: Disable Swap ============
echo "Disabling Swap......."
sudo swapoff -a
sudo sed -i '/^[^#]/ s/\(^.*swap.*$\)/#\1/' /etc/fstab
free -h
echo ""
#!/bin/bash
# Function to prompt for MySQL details
prompt_mysql_details() {
read -p "Enter MySQL database name: " DBNAME
read -p "Enter MySQL username: " DBUSER
read -sp "Enter MySQL password: " DBPASS
echo
}
@amircloner
amircloner / wireguardOverWebsocket.md
Created October 24, 2022 16:08 — forked from alikarimii/wireguardOverWebsocket.md
Set Up a Wireguard VPN Server with WebSocket Tunneling

این آموزش مربوط به سیستم های یونیکسه.

CDN

خب اول یک دامنه یا ساب دامنه انتخاب کنید و یک A رکورد به مقدار آی پی سرور خارجی و پرت HTTPS بسازید.سی دی ان داخلی باشه که طرح رذالتو دور بزنید. باید روی SSL,CDN رو فعال کنید.

SSL

خب برای اون دامنه باید اس اس ال داشته باشید با این فایل ها fullchain.pem, privkey.pem, chain.pem, dhparam.pem آموزش گرفتن اس اس ال هم که زیاده. (dhparam- Diffie–Hellman (D-H))

NGINX

اول nginx رو روی سرور خارجی نصب کنید.

@amircloner
amircloner / Google-Sheet-Form-Post.md
Last active September 12, 2021 04:44 — forked from willpatera/Google-Sheet-Form-Post.md
Post to google spreadsheet from html form

Overview

This collection of files serves as a simple static demonstration of how to post to a google spreadsheet from an external html <form> following the example by Martin Hawksey

Depreciation Warning: This code is not maintained, and should be seen as reference implementation only. If you're looking to add features or update, fork the code and update as needed.

Run example

You should be able to just open index.html in your browser and test locally.