Skip to content

Instantly share code, notes, and snippets.

View dennybaa's full-sized avatar

Denis Baryshev dennybaa

View GitHub Profile
@dennybaa
dennybaa / deployment.yml
Created April 12, 2019 05:48 — forked from troyharvey/deployment.yml
Using Kubernetes envFrom for environment variables #k8s #envfrom
# Use envFrom to load Secrets and ConfigMaps into environment variables
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: mans-not-hot
labels:
app: mans-not-hot
spec:
replicas: 1
@dennybaa
dennybaa / semver-regex.md
Last active April 4, 2019 13:21 — forked from jhorsman/semver-regex.md
Semantic versioning regex #semver #regex

Semantic versioning regex

^([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+)?$

^([0-9]|[1-9][0-9]*)\.([0-9]|[1-9][0-9]*)\.([0-9]|[1-9][0-9]*)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?$

example

http://regexr.com/3er1i

also see

@dennybaa
dennybaa / docker-cleanup-resources.md
Last active August 6, 2018 17:20 — forked from bastman/docker-cleanup-resources.md
docker cleanup guide: containers, images, volumes, networks #docker #cleanup #cli

Docker

exec: Preserve terminal with and colors

Exec preserving terminal options:

$ docker exec -ti --env COLUMNS=`tput cols` --env LINES=`tput lines` ...

run: Pass through SSH_AUTH_SOCK