Skip to content

Instantly share code, notes, and snippets.

View jonashackt's full-sized avatar
:octocat:
TDD & CI for IaC FTW!

Jonas Hecht jonashackt

:octocat:
TDD & CI for IaC FTW!
View GitHub Profile
@andrealbinop
andrealbinop / setup-modernie-vagrant-boxes.md
Last active May 28, 2023 01:54
Setup modern.ie vagrant boxes

Setup modern.ie vagrant boxes

Since modern.ie released vagrant boxes, it' no longer necessary to manually import the ova file to virtualbox, as mentioned here.

However, the guys at modern.ie didn't configured the box to work with WinRM. This how-to addresses that, presenting steps to proper repackage these boxes, adding WinRM support. Additionally configures chocolatey package manager and puppet provisioner.

Pre-requisites

@jonashackt
jonashackt / maven-repos.html
Last active September 4, 2020 12:57
Release-Stuff: Maven Repos to look after releasing
In order of occurrence:
https://repo1.maven.org/maven2/de/codecentric/cxf-spring-boot-starter-maven-plugin/
https://search.maven.org/#search%7Cga%7C1%7Ca%3A%22cxf-spring-boot-starter-maven-plugin%22
https://mvnrepository.com/artifact/de.codecentric/cxf-spring-boot-starter-maven-plugin
https://github.com/codecentric/spring-boot-admin/issues?utf8=%E2%9C%93&q=milestone%3A1.4.4%20

How to add an image to a gist

  1. Create a gist if you haven't already.
  2. Clone your gist:
    # make sure to replace `<hash>` with your gist's hash
    git clone https://gist.github.com/<hash>.git # with https
    git clone git@gist.github.com:<hash>.git     # or with ssh
@jonashackt
jonashackt / powershell.md
Last active February 27, 2018 13:59
Powershell cheatsheet

Start Powershell from cmd

start powershell

Resolve a DNS name:

Resolve-DnsName

Get PortMapping (e.g. if HNS error - object already exists occurs)

Get-NetNatStaticMapping

...and remove the failing PortMapping with (but LOOK, it goes through all mapping with the same NatName

- so if you only want to remove one, then just say Yes there)

@pierrejoubert73
pierrejoubert73 / markdown-details-collapsible.md
Last active May 24, 2024 14:17
How to add a collapsible section in markdown.

How to add a collapsible section in markdown

1. Example

Click me

Heading

  1. Foo
  2. Bar
    • Baz
  • Qux
@jonashackt
jonashackt / Linux-cheatsheet.sh
Last active January 29, 2021 18:47
Linux cheatsheet (Ubuntu)
# 0. need root access to system
#### Show environment variables
printenv
#### Set env var
export FOO=BAR
#### Set env var for root
# sudo export FOO=BAR doesnt work! (see https://askubuntu.com/questions/272637/i-have-a-problem-when-using-export-command)
@jonashackt
jonashackt / kubernetes-cheatsheet.md
Last active March 13, 2024 13:36
Kubernetes cheat sheet
@jonashackt
jonashackt / Jekyll-GitHub-Pages-Cheatsheet.sh
Last active November 25, 2019 16:09
Jekyll with GitHub-Pages Cheatsheet
# Update Jekyll GitHub-Pages site
https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/#keeping-your-site-up-to-date-with-the-github-pages-gem
bundle update github-pages
# Test Jekyll with GitHub-Pages locally
https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/#step-4-build-your-local-jekyll-site
bundle exec jekyll serve
@jonashackt
jonashackt / NanoCheatsheet.sh
Created December 7, 2018 08:36
Nano cheatsheet
# Go to last line
Crtl + Shift + _
Crtl V
# Delete whole line
Crtl + K
@jonashackt
jonashackt / dockercheatsheet.md
Last active July 13, 2021 15:12
Docker cheatsheet

Docker container, images, networks management is easy with the prune command which is available for all types of Docker artifacts (see https://stackoverflow.com/a/32723127/4964553 & https://docs.docker.com/config/pruning/#prune-images & https://docs.docker.com/engine/reference/commandline/system_prune/#filtering).

remove all local Docker containers, that are older than

docker container prune --filter "until=48h"

remove all local Docker images, that are older than

docker image prune -a --filter "until=2020-10-25"

run multiple commands with only one single docker run