Skip to content

Instantly share code, notes, and snippets.

View JeyDi's full-sized avatar
🚀
To infinity... and beyond!

Andrea Guzzo JeyDi

🚀
To infinity... and beyond!
View GitHub Profile
@irazasyed
irazasyed / outbound-email-with-cloudflare.md
Last active June 15, 2025 19:33
Using Gmail SMTP with Cloudflare Email Routing: A Step-by-Step Guide

Using Gmail SMTP with Cloudflare Email Routing: Step-by-Step Guide

Learn how to send emails through Gmail SMTP with Cloudflare Email Routing in this comprehensive guide.

Step 1: Enable 2-Factor Authentication

To proceed with this method, ensure that you have enabled two-factor authentication for your Google account. If you haven't done so already, you can follow the link to set it up → Enable 2FA in your Google account.

Step 2: Create an App Password for Mail

@soof-golan
soof-golan / Dockerfile
Last active March 29, 2025 06:05
Python + Poetry + Docker Example
FROM python:3.10 as python-base
# https://python-poetry.org/docs#ci-recommendations
ENV POETRY_VERSION=1.2.0
ENV POETRY_HOME=/opt/poetry
ENV POETRY_VENV=/opt/poetry-venv
# Tell Poetry where to place its cache and virtual environment
ENV POETRY_CACHE_DIR=/opt/.cache
@bruno-uy
bruno-uy / install_psycopg2_mac_m1.md
Last active May 26, 2025 12:27
Install psycopg2 in Mac M1

Install psycopg2 in Mac M1

Error while installing through pip install psycopg2 looks like this:

Please add the directory containing pg_config to the PATH

or specify the full executable path with the option (...)

Reference to the solution here.

@whatupfoo
whatupfoo / 1-orgs-archetype.md
Last active May 2, 2025 12:02
Orgs and Teams Best Practices

Organization archetypes

The intention of this document is to provide some guidance and suggestions to customers who are wondering how they should structure organizations and teams in their GitHub Enterprise environment. The idea isn't to give hard and fast rules on which approach is better than the other, but to give examples of when one approach might be preferable to another depending on the use case.

1. A single organization with direct organization membership for repository access (not teams)

          ________________
          |     Org      |
          |    ______    |
          |   |      |\  |

| | Repo | \ |

@bluesmilery
bluesmilery / s3_python_client.py
Created March 17, 2020 03:58
[s3_python_client] #s3
# -*- coding: utf-8 -*-
# ===============================================================
#
# @Create Author : bluesmilery
# @Create Time : 2019/11/25 15:51
# @Description : S3客户端
#
# ===============================================================
@rchakode
rchakode / prometheus_exporter_system_resource_usage.py
Last active August 14, 2024 09:30
Sample Python program providing a Prometheus exporter that exposes system CPU and memory usage every 5 minutes.
import prometheus_client
import time
import psutil
UPDATE_PERIOD = 300
SYSTEM_USAGE = prometheus_client.Gauge('system_usage',
'Hold current system resource usage',
['resource_type'])
if __name__ == '__main__':
@magicdude4eva
magicdude4eva / zsh-syntax-highlighting paste performance improvement
Last active April 25, 2025 19:23
zsh-syntax-highlighting paste performance improvement
Add the following in .zshrc:
...
plugins=(osx git zsh-autosuggestions zsh-syntax-highlighting zsh-nvm docker kubectl)
...
### Fix slowness of pastes with zsh-syntax-highlighting.zsh
pasteinit() {
OLD_SELF_INSERT=${${(s.:.)widgets[self-insert]}[2,3]}
zle -N self-insert url-quote-magic # I wonder if you'd need `.url-quote-magic`?
@bradtraversy
bradtraversy / docker-help.md
Last active June 3, 2025 21:01
Docker Commands, Help & Tips

Docker Commands, Help & Tips

Show commands & management commands

$ docker

Docker version info

@valferon
valferon / postgres_manager.py
Created March 29, 2018 02:35
Python script to take care of postgres backup and restore of data
#!/usr/bin/python3
import argparse
import logging
import subprocess
import os
import tempfile
from tempfile import mkstemp
import configparser
import gzip
@rordi
rordi / docker-debug.md
Last active July 15, 2024 20:30
Docker debugging an existing image

Debugging a Docker image

Start up the Docker container from image:

docker run --entrypoint "/bin/sh" --rm imagename:latest -c "sleep 24h"

Obtain the container hash id:

docker ps