Skip to content

Instantly share code, notes, and snippets.

View dragonde's full-sized avatar
💭
Ready, Steady & Go!

dragonde

💭
Ready, Steady & Go!
View GitHub Profile
@dragonde
dragonde / xpack-security.md
Created August 2, 2022 09:15
Elasticsearch xpack security

esConfig: elasticsearch.yml: | xpack.security.enabled: true xpack.security.transport.ssl.enabled: true xpack.security.transport.ssl.verification_mode: full xpack.security.transport.ssl.keystore.path: /usr/share/elasticsearch/config/certs-gen/keystore.p12 xpack.security.transport.ssl.truststore.path: /usr/share/elasticsearch/config/certs-gen/keystore.p12 xpack.security.authc: anonymous: username: anonymous

@dragonde
dragonde / macos-keyboard.md
Last active December 5, 2022 10:15
Mac Keyboard Configuration
@dragonde
dragonde / timectl-set-localtime.md
Last active September 29, 2023 14:54
Linux Set localtime

Set local time

Windows use localtime instead of UTC like linux

timedatectl set-local-rtc 0 --adjust-system-clock

To revert

@dragonde
dragonde / vs-kubernetes.md
Last active December 20, 2023 10:32
kubectl not found in vscode

(CMD/CTRL + SHIFT + P)

Search for: Open User Settings (JSON)

click on Preferences: Open User Settings (JSON)

"vs-kubernetes": {

"vs-kubernetes.kubectl-path": "/snap/bin/kubectl"

@dragonde
dragonde / zshrc
Last active July 28, 2024 10:15
Zshrc - Configuration with Oh my zsh
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH="$HOME/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes
@dragonde
dragonde / bashrc
Created January 3, 2024 10:04
Bashrc - Configuration
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
@dragonde
dragonde / k8s-list.md
Last active January 3, 2024 13:12
Kubernetes List Containers

List all containers in ALL namespaces

kubectl get pods --all-namespaces -o jsonpath="{.items[].spec['initContainers', 'containers'][].image}" |
tr -s '[[:space:]]' '\n' |
sort |
uniq -c

kubectl get pods --all-namespaces -o json |
jq -r '.items[].spec | .initContainers[].image, .containers[].image' | \

@dragonde
dragonde / notes.md
Created January 3, 2024 10:11
Notas[object Object]

bash

set -euxo pipefail is short for:

set -e
set -u
set -o pipefail
set -x