Skip to content

Instantly share code, notes, and snippets.

View tonejito's full-sized avatar
🐰
= ^ . ^ =

Andres Hernandez tonejito

🐰
= ^ . ^ =
View GitHub Profile

Iniciar servicio PostgreSQL con un contenedor en utility

Iniciar sesion en utility.

[student@workstation ~]$ ssh lab@utility
[lab@utility ~]$
@tonejito
tonejito / .gitignore
Last active June 2, 2023 01:59
Harry Potter and the cursed ARO k8s volume mounts
# .gitignore
**/old
@tonejito
tonejito / find-unused-images
Last active May 18, 2022 16:35
Find unused images in a book repo
#!/bin/bash
# = ^ . ^ =
set -u
set -o pipefail
AVAILABLE=/tmp/available-images.txt
USED=/tmp/used-images.txt
DIFF=/tmp/diff-images.txt
UNUSED=/tmp/unused-images.txt
@tonejito
tonejito / test-requests-short.py
Last active February 3, 2022 18:31
Test for the Python requests module
#!/usr/bin/env python3
# Test for the Python requests module
# https://docs.python-requests.org/en/latest/user/quickstart/
# https://docs.python-requests.org/en/latest/user/advanced/
# https://docs.python-requests.org/en/latest/api/
import requests
#!ipxe
kernel http://cdn-fastly.deb.debian.org/debian/dists/stable/main/installer-amd64/current/images/netboot/debian-installer/amd64/linux expert theme=dark priority=low
initrd http://cdn-fastly.deb.debian.org/debian/dists/stable/main/installer-amd64/current/images/netboot/debian-installer/amd64/initrd.gz
boot
@tonejito
tonejito / technologic.sh
Last active September 16, 2020 11:55
Daft Punk - Technologic
#!/bin/bash
# = ^ . ^ =
# say -v ? | grep en_US
# VOICE=Alex
# VOICE=Fred
VOICE=Samantha
# VOICE=Victoria
@tonejito
tonejito / get-CV-data.sh
Last active April 25, 2020 08:41
Pull CV data from official site and convert it to JSON format
#!/bin/bash
# Andrés Hernández (tonejito)
# This script is released under the terms of the BSD 2 clause license
set -evx
SITE="coronavirus.gob.mx"
ENDPOINT="datos"
DATA_FILE="Downloads/filesDD.php"
@tonejito
tonejito / Makefile
Last active January 29, 2020 17:16
Compile @python 3.x for older systems
SHELL=/bin/bash
# = ^ . ^ =
APT_OPTS=-q=2 --assume-yes
APT_DEPS=build-essential \
tcl-dev tk-dev \
libpq-dev libffi-dev zlib1g-dev libreadline-dev libbz2-dev libncurses-dev libdbm-ocaml-dev libgdbm-dev liblzma-dev libsqlite3-dev uuid-dev libxml2-dev libxslt-dev \
libssl-dev openssl \
python3-pip python3-dev
@tonejito
tonejito / mock.conf
Created January 8, 2020 03:07
just a @nginx mockup
server {
listen 80 default_server;
listen [::]:80 default_server;
root /var/www/html;
index index.html index.htm index.nginx-debian.html;
server_name _;
location / {
return 200 "<html><body><h1>It works</h1></body></html>";
add_header Content-Type text/html;
}
@tonejito
tonejito / microsoft-sucks.log
Last active December 19, 2019 00:56
./microsoft-sucks.sh 2>&1 | tee microsoft-sucks.log
#!/bin/bash -v
DOMAIN=microsoft.sucks.
whois ${DOMAIN}
% IANA WHOIS server
% for more information on IANA, visit http://www.iana.org
% This query returned 1 object
refer: whois.nic.sucks