Skip to content

Instantly share code, notes, and snippets.

View jforge's full-sized avatar

jforge

  • Germany, Bargteheide
  • 08:08 (UTC +02:00)
View GitHub Profile
@jforge
jforge / bash_strict_mode.md
Created February 9, 2023 12:42 — forked from mohanpedala/bash_strict_mode.md
set -e, -u, -o, -x pipefail explanation
# https://git-scm.com/docs/git-rev-parse
$ ~/git/abc/xyz/123   main ±✚  git rev-parse --show-toplevel
/Users/me/git/abc/
$ ~/git/abc/xyz/123   main ±✚  git rev-parse --show-prefix
xyz/123/
$ ~/git/abc/xyz/123   main ±✚  git rev-parse --show-cdup
// Disclaimer: this is provided “as is” without warranty of any kind, either expressed or implied and such is to be used at your own risk.
// Dependencies
// ----------------------
// Setting up Github credential with Jenkins's Credential Manager ( https://www.youtube.com/watch?v=HSA_mZoADSw&t=40s )
// Jenkins Plugin to Clean Workspace ( https://plugins.jenkins.io/ws-cleanup/ )
// Large File Storage ( https://git-lfs.github.com/ )
// Variables
// ----------------------
// Disclaimer: this is provided “as is” without warranty of any kind, either expressed or implied and such is to be used at your own risk.
// Dependencies
// ----------------------
// Setting up Github credential with Jenkins's Credential Manager ( https://www.youtube.com/watch?v=HSA_mZoADSw&t=40s )
// Jenkins Plugin to Clean Workspace ( https://plugins.jenkins.io/ws-cleanup/ )
// Large File Storage ( https://git-lfs.github.com/ )
// Variables
// ----------------------
@jforge
jforge / _0__ssl_certbot_letsencrypt.md
Created November 18, 2022 18:07 — forked from maxivak/_0__ssl_certbot_letsencrypt.md
Let's encrypt SSL certificates using certbot in docker

Directories on host machine:

  • /data/certbot/letsencrypt

  • /data/certbot/www

  • Nginx server in docker container

docker run -d --name nginx \
# Source: TODO:
#########
# TODO: #
# TODO: #
#########
# Additional Info:
# - Production-Ready Kubernetes Clusters Using Crossplane Compositions: https://youtu.be/uMC2QQfMctg
# - How To Shift Left Infrastructure Management Using Crossplane Compositions: https://youtu.be/AtbS1u2j7po
@jforge
jforge / 00-infra.yaml
Created August 31, 2022 12:22 — forked from abdennour/00-infra.yaml
Jenkins declarative Pipeline in Kubernetes with Parallel and Sequential steps
apiVersion: v1
kind: Pod
spec:
# dnsConfig:
# options:
# - name: ndots
# value: "1"
containers:
- name: dind
image: abdennour/docker:19-dind-bash
@jforge
jforge / x11_forwarding_macos_docker.md
Last active August 22, 2022 07:53 — forked from sorny/x11_forwarding_macos_docker.md
X11 forwarding with macOS and Docker

X11 forwarding on macOS and docker

A quick guide on how to setup X11 forwarding on macOS when using docker containers requiring a DISPLAY.

This guide was tested on:

  • macOS Catalina 10.15.4
  • docker desktop 2.2.0.5 (43884) - stable release
  • XQuartz 2.7.11 (xorg-server 1.18.4)

Works also with:

  • macOS Monterey 12.5 (21G72)
1. Go to Google Chrome
2. Go to any website (works cool on facebook)
3. Right click anywhere -> Inspect Element
4. Click on the rightmost "Console" tab.
5. Copy paste the following * into the console.
6. Make sure the volume isn't too loud!
6. Press Enter.
* Copy paste the following text in the console: