Skip to content

Instantly share code, notes, and snippets.

View gionn's full-sized avatar

Giovanni Toraldo gionn

View GitHub Profile

Global User Preferences

Git

Never run git push. The user always pushes manually. Commit when asked, but leave pushing to the user.

When a request implies the branch has already been pushed (e.g. "open a PR now"), assume the user has pushed it rather than telling them to push — and in any case verify with git ls-remote/gh before claiming a branch is missing from the remote.

Do not add Co-Authored-By trailer lines to commit messages.

@gionn
gionn / github_org_scanner.py
Created September 16, 2025 13:52
A Python script to scan GitHub organizations and list all public repositories of their members - useful for security auditing.
#!/usr/bin/env python3
"""
GitHub Organization Scanner
A script to list all users in a specific GitHub organization
and enumerate their public/open source repositories.
Usage:
python github_org_scanner.py <organization_name>

Keybase proof

I hereby claim:

  • I am gionn on github.
  • I am gionn (https://keybase.io/gionn) on keybase.
  • I have a public key ASDn1tEToDgBr0ogQDwCbkH0YlPsKbLdXuRA9Ymn2feMcgo

To claim this, I am signing this object:

@gionn
gionn / graviton.yaml
Last active March 11, 2024 14:47
Helm values for installing Alfresco on EKS with Graviton nodes with Helm Charts v8.x.x
alfresco-control-center:
nodeSelector:
"kubernetes.io/arch": arm64
ingress:
hosts:
- host: FQDN
paths:
- path: /control-center
pathType: Prefix
tls:
#!/usr/bin/env bash
namespace=${1-fleet-default}
delete_before_timestamp=${2-2000-01-01T00:00:00Z}
jsonPath='{range .items[*]}{@.metadata.creationTimestamp}{"_"}{@.metadata.name}{"_"}{@.spec.clusterLabels.management\.cattle\.io/cluster-name}{"\n"}{end}'
cluster_regs=$(kubectl get clusterregistration -o=jsonpath="$jsonPath" -n $namespace | sort)
read -ra regs -d '' <<< "${cluster_regs}"
last_idx=$(( ${#regs[@]} - 1 ))
for (( i = 0; i < $last_idx; i+= 1 )); do
@gionn
gionn / sources.list
Created June 16, 2023 19:45
Debian 12 Bookwork sources.list
deb http://deb.debian.org/debian/ bookworm main contrib non-free non-free-firmware
deb http://security.debian.org/ bookworm-security non-free contrib main non-free-firmware
deb http://deb.debian.org/debian/ bookworm-updates non-free contrib main non-free-firmware
deb http://deb.debian.org/debian/ bookworm-backports main contrib non-free non-free-firmware
@gionn
gionn / components.yaml
Last active January 23, 2023 11:10
Patched metrics-server v0.6.2 to make it work on EKS
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
k8s-app: metrics-server
name: metrics-server
namespace: kube-system
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@gionn
gionn / macos-fix.md
Created May 4, 2022 07:42
How to make macos working for the average Linux user

MacOs Fix

This is a reminder for all the things I changed to improve my experience using MacOs as a Linux user.

  • External (third-party) mouse scrolling is broken due to accelleration. Fix it with Mac Mouse Fix
  • Clipboard manager with handy history dialog. See Maccy
@gionn
gionn / opera-prune.service
Created January 9, 2022 10:36
Fantom opera systemd service for node and pruning
[Unit]
Description=FTM Node daemon for Pruning Snapshot
[Service]
User=peastew
Type=oneshot
WorkingDirectory=/usr/local/bin
ExecStart=/usr/local/bin/opera --genesis /home/peastew/.opera/mainnet.g --cache 16384 --config /home/peastew/.opera/config.toml --datadir /home/peastew/.opera snapshot prune-state
PIDFile=/home/peastew/.opera/ftmnodeprune.pid
Restart=no
@gionn
gionn / gist:cb1a60e15b8cbfeeeec4dc5aafddc75b
Created August 30, 2021 07:32
Check the expiration date of an SSL certificate exposed by a local webserver (nginx, SNI, letsencrypt)
openssl s_client -connect localhost:443 -servername server.domain.tld | openssl x509 -noout -dates