Skip to content

Instantly share code, notes, and snippets.

View yashodhank's full-sized avatar
🎯
Manifesting

Yashodhan yashodhank

🎯
Manifesting
View GitHub Profile
@yashodhank
yashodhank / urllib.error.URLError-solutions.md
Created September 26, 2023 10:08
urllib.error.URLError; <urlopen error [SSL: CERTIFICATE _VERIFY _FAILED] certificate verify failed; unable to get local issuer certificate (_ss1.c:1051)>

The error message indicates that the program is facing an SSL certificate verification error while trying to open a URL. This error occurs because the SSL certificate of the site that the program is trying to access cannot be verified by a local Certificate Authority (CA).

Here’s a step-by-step guide to help you resolve the SSL certificate error:

Step 1: Update CA Certificates

Firstly, ensure that the CA certificates on your system are up to date. You can do this by updating the certifi package using pip:

pip install --upgrade certifi
@yashodhank
yashodhank / script.sh
Created September 4, 2023 07:44 — forked from aleksul/script.sh
Proxmox create Ubuntu 20.04 template
# download ubuntu-cloud image
# NOTE: ubuntu-server won't properly work with cloud-init for some reason
wget https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img
# NOTE: no need for sudo because we already login as root
# install image customization tool
apt update -y && apt install libguestfs-tools -y
# install qemu-guest-agent inside of image
@yashodhank
yashodhank / proxmox-packer-user-creator.sh
Created September 4, 2023 01:20
This script automate the process to create random username and password and required role with privilages for Packer to work with Proxmox Host.
#!/bin/bash
# Function to generate a strong password
generate_password() {
cat /dev/urandom | tr -dc 'a-zA-Z0-9!@#$%^&*()-_+=~' | fold -w 16 | head -n 1
}
# Function to generate a random username
generate_username() {
cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 8 | head -n 1
@yashodhank
yashodhank / Order-Create.cshtml-dev.md
Last active July 28, 2023 18:30
DRSApp development Document Related to Order & OrderBOM
@using KlausBOM.DTOs.Orders
@using KlausBOM.DTOs.ProductConfigs
@using KlausBOM.DTOs.Products
@using KlausBOM.Domain
@using KlausBOM.Domain.Enumerations
@using KlausBOM.Models
@using KlausBOM.Utility
@using System.Security.Claims
@yashodhank
yashodhank / homebrew.mxcl.aria2.plist
Last active January 10, 2026 04:50 — forked from stackia/homebrew.mxcl.aria2.plist
aria2c daemon start at boot. Put this file into /Library/LaunchDaemons, them 'chmod 600' and 'chown root'. Remember to fill REPLACE_WITH_YOUR_ placeholders below.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>KeepAlive</key>
<true/>
<key>RunAtLoad</key>
<true/>
<key>Label</key>
<string>homebrew.mxcl.aria2</string>
@yashodhank
yashodhank / custom.ipxe
Created April 22, 2023 05:11 — forked from bunchc/custom.ipxe
Custom ipxe menu for netboot.xyz
#!ipxe
###
### codybunch.lab custom menu example
###
:custom
clear custom_choice
menu ESXi
item --gap Boot ESXi Installer
item esxi_70_kickstart ${space} 7.0 Automated Install
@yashodhank
yashodhank / HowToDeleteAllCloudflareRecors.md
Created December 4, 2022 10:34 — forked from AidasK/HowToDeleteAllCloudflareRecors.md
Cloudflare delete all DNS records. Just go to cloudflare dns zones, open your browers developer console and paste this javascript code.

image

Real developers are not used to clicking, it's allways easier to write a script to do it for you.
@yashodhank
yashodhank / docker-compose.yml
Last active November 28, 2022 01:33 — forked from smashnet/docker-compose.yml
Docker-Compose: Mastodon v4.0.2 with Traefik v2.9
version: "3.9"
# Install docker on Linux
# curl -fsSL https://get.docker.com | sudo sh
# Variables to fill in:
# Line 44: <LETSENCRYPT_MAIL_ADDRESS> - your mail address for contact with Let's Encrypt
# Line 57: <TRAEFIK_DASHBOARD_ADMIN_PASSWORD> - MD5 hash of your password (use http://www.htaccesstools.com/htpasswd-generator/)
# Line 76: <POSTGRES_PASSWORD> - the password for the postgres db. Use the same during mastodon:setup!
# Lines 52, 110, 136: <DOMAIN> - e.g. social.yourdomain.com (Must have an A record pointing to your box' IP) (AAAA for IPv6 ;)
@yashodhank
yashodhank / gist:96dc27d6a1e1899b398e33819c19baa2
Created November 19, 2022 06:00 — forked from Darkflib/gist:8c40e9e0bb60883bd70fb34972b5954a
minio gateway to s3 compatible wasabi with cache + s3fs and ecryptfs
mkdir /mnt/wasabi-cache
lvcreate -L 100G -n wasabi-cache vg0
mkfs.ext4 /dev/vg0/wasabi-cache
docker run -d -p 9000:9000 --name minio-wasabi -e "MINIO_CACHE_DRIVES=/mnt/wasabi-cache" -e "MINIO_CACHE_EXPIRY=40" \
-e "MINIO_ACCESS_KEY=AKKEYKEYKEYKEYKEY" -e "MINIO_SECRET_KEY=mysecret123123123123123" \
minio/minio gateway s3 https://s3.wasabisys.com:443
@yashodhank
yashodhank / Tweet functions.gs
Created September 15, 2022 22:35 — forked from iamdaniele/Tweet functions.gs
Add public metrics
const BearerTokenKey = 'twitterBearerToken';
function onOpen() {
SpreadsheetApp
.getUi()
.createMenu('Twitter')
.addItem('Set Bearer token', 'helpers.requestBearerToken')
.addItem('Sign out', 'helpers.logout')
.addToUi();
}