Skip to content

Instantly share code, notes, and snippets.

View ZeroDeth's full-sized avatar
🏠
Working from home

Sherif Abdalla ZeroDeth

🏠
Working from home
View GitHub Profile

Traefik Enterprise Installaion

Prerequisites

  1. Create a GKE CLUSTER v125.8-gke.500 with Linkderd 2
  2. Set license, cluster and namespace
export NAMESPACE=traefikee
export CLUSTERNAME=default
export TRAEFIKEE_LICENSE=<your-license-here>
@ZeroDeth
ZeroDeth / install-copilot.sh
Created March 23, 2023 10:24 — forked from JonhSHEPARD/install-copilot.sh
Github Copilot on NixOS
#!/bin/sh
if [ "$EUID" -ne 0 ]
then echo "This script must be run as root"
exit
fi
if [ "$#" -ne 1 ]; then
echo "Usage: ./$0 <path-to-ide"
exit 1
@ZeroDeth
ZeroDeth / pre-commit
Created February 22, 2023 14:51 — forked from ilyakatz/pre-commit
helpful precommit hooks
#!/bin/bash -l
# A git hook script to find and fix trailing whitespace
# in your commits. Bypass it with the --no-verify option
# to git-commit
#
.git/hooks/pre-commit-master-no-no
if [[ $? == 1 ]]
then

Installing on Linode

I copied the bulk of this guide from Andrew Miller's NixOS-On-Linode.md instructions. It's a very well-written guide, but I felt we could make things a bit more simple than he left them in his original guide.

This tutorial is written for people who want to run NixOS on a Linode instance. The installation is pretty straightforward, but it involves some bootstrapping using Linode's tools.

In this tutorial, we will show you how to set up NixOS on Linode by setting up disks (including the installation live CD) using the rescue OS, and use the minimal live CD to install NixOS onto your disk.

Create a Linode

@ZeroDeth
ZeroDeth / Readme.md
Created November 19, 2022 18:38 — forked from rms1000watt/Readme.md
Github Actions --> AWS OIDC in Terraform
Byobu is a suite of enhancements to tmux, as a command line
tool providing live system status, dynamic window management,
and some convenient keybindings:
F1 * Used by X11 *
Shift-F1 Display this help
F2 Create a new window
Shift-F2 Create a horizontal split
Ctrl-F2 Create a vertical split
Ctrl-Shift-F2 Create a new session
@ZeroDeth
ZeroDeth / terraform-presigned-url.tf
Created July 8, 2022 13:36 — forked from kharandziuk/terraform-presigned-url.tf
A hack to generate a presigned url in terraform
variable "bucket_name" {
default = "max-bucket-for-testing"
}
provider "aws" {
region = var.aws_region
profile = var.aws_profile
}
resource "aws_s3_bucket" "artifacts" {
@ZeroDeth
ZeroDeth / aws-rds-connection-test.yaml
Created June 11, 2022 22:22
spin up a pod and connect from the pod itself
apiVersion: v1
kind: Pod
metadata:
name: mysql-rds-connection-test
namespace: default
spec:
containers:
- name: mysqlconn
image: mysql:latest
command: ['mysql']
@ZeroDeth
ZeroDeth / remove-k8s-namespace-finalizer.sh
Last active May 12, 2022 19:28
Script to force remove Kubernetes Namespace Finalizer
#!/bin/bash
set -eou pipefail
namespace=$1
if [ -z "$namespace" ]
then
echo "This script requires a namespace argument input. None found. Exiting."
exit 1
@ZeroDeth
ZeroDeth / GPG and git on macOS.md
Created April 24, 2022 10:29 — forked from danieleggert/GPG and git on macOS.md
How to set up git to use the GPG Suite

GPG and git on macOS

Setup

No need for homebrew or anything like that. Works with https://www.git-tower.com and the command line.

  1. Install https://gpgtools.org -- I'd suggest to do a customized install and deselect GPGMail.
  2. Create or import a key -- see below for https://keybase.io
  3. Run gpg --list-secret-keys and look for sec, use the key ID for the next step
  4. Configure git to use GPG -- replace the key with the one from gpg --list-secret-keys