Skip to content

Instantly share code, notes, and snippets.

View KimmoHernborg's full-sized avatar

Kimmo Hernborg KimmoHernborg

  • Sweden
  • 23:02 (UTC +02:00)
View GitHub Profile
@mrk-han
mrk-han / expo-azure.yml
Last active February 28, 2025 17:10
Simple Guide for a Build and Testing Pipeline with Expo and EAS from Azure Devops CICD (Managed Workflow)
# https://aka.ms/yaml
trigger:
branches:
include:
- main
- releases/*
- hotfix/*
pr:
autoCancel: true
@scyto
scyto / docker-swarm-architecture.md
Last active April 25, 2025 21:04
My Docker Swarm Architecture

This (and related gists) captures how i created my docker swarm architecture. This is intended mostly for my own notes incase i need to re-creeate anything later! As such expect some typos and possibly even an error...

Installation Step-by-Step

Each major task has its own gist, this is to help with maitainability long term.

  1. Install Debian VM for each docker host
  2. install Docker
  3. Configure Docker Swarm
  4. Install Portainer
  5. Install KeepaliveD
  6. Using VirtioFS backed by CephFS for bind mounts (migrating from glsuterFS - WIP)
@sugoidogo
sugoidogo / 0-pve.sh
Last active March 29, 2025 01:00
customized install proxmox ve on debian - only tested on buster, bullseye
#!/usr/bin/env bash
# wget -qO 0-pve.sh https://gist.github.com/sugoidogo/4684e4659431e17d15be20171160c1f9/raw/ && bash 0-pve.sh
set -e
export DEBIAN_FRONTEND=noninteractive
export APT_LISTCHANGES_FRONTEND=none
function download { wget $* || curl -fLO $*; }
function stream { wget -qO- $* || curl -fsSL $*; }
function package { apt $* || dnf $*; }
echo "This script will download and run the installation script in a screen session"
echo "The installation script will download post-installation scripts to $HOME and reboot the system upon successful installation"
@davidteren
davidteren / nerd_fonts.md
Last active April 27, 2025 13:47
Install Nerd Fonts via Homebrew [updated & fixed]
<#
Create Unix VM's.
PREREQUISITES:
- A VM that has been installed with an OS that supports cloud-init
- cloud-init is installed on the vm
How it works:
- Asks for a bunch of parameters
- Creates a disk from parent vhdx for speed
@hjbotha
hjbotha / traefik.sh
Last active April 13, 2020 12:05
wrapper script to daemonise traefik
#! /bin/bash
set -e
#set -x
ROOT=$(dirname $0)
cd $ROOT
# export your cloudflare API key by uncommenting or placing the following lines (uncommented) in traefik.conf
@amcvitty
amcvitty / password_autofill_expo_how_to.md
Last active February 25, 2025 10:53
Configure Password Autofill on a React Native Expo app

Password Autofill on a React Native Expo app

Developing an app to accompany our website, worried that we would lose people in the transition if they couldn't remember their password, we were looking to make our app do Password AutoFill, a feature in iOS.

A talk from WWDC introducing the feature: https://developer.apple.com/videos/play/wwdc2017/206/

It works well, but there were a few bumps in the road making it work for React Native on Expo, so here are some notes to help out.

Apple's docs are here: https://developer.apple.com/documentation/security/password_autofill and they say something like this:

@aprilmintacpineda
aprilmintacpineda / Using Multiple SSH keys - Beginner Friendly.md
Last active April 28, 2025 13:14
Beginner Friendly: Using Multiple SSH keys

How to follow this guide

The problem

I have one computer and two different github accounts. One is for work, the other is for my personal stuff. I can't use the same ssh key twice, so I have to use different ssh key for each of my accounts. How do I do that? How do I switch between these ssh keys?

@styblope
styblope / docker-api-port.md
Last active April 24, 2025 13:32
Enable TCP port 2375 for external connection to Docker

Enable TCP port 2375 for external connection to Docker

See this issue.
Docker best practise to Control and configure Docker with systemd.

  1. Create daemon.json file in /etc/docker:

     {"hosts": ["tcp://0.0.0.0:2375", "unix:///var/run/docker.sock"]}
    
@barsv
barsv / logger.ps1
Last active March 14, 2025 02:34
Logging in powershell with log rotation
# all logging settins are here on top
$logFile = "log-$(gc env:computername).log"
$logLevel = "DEBUG" # ("DEBUG","INFO","WARN","ERROR","FATAL")
$logSize = 1mb # 30kb
$logCount = 10
# end of settings
function Write-Log-Line ($line) {
Add-Content $logFile -Value $Line
Write-Host $Line