Skip to content

Instantly share code, notes, and snippets.

Kevin Krummenauer kekru

Block or report user

Report or block kekru

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
kekru /
Created Nov 29, 2017
Install Docker Client (CLI) on Linux
set -e
mkdir -v --parents $DIR
# | tar xvz --directory $DIR
curl | tar xvz --directory $DIR
mv -v $DIR/docker/docker /usr/local/bin/docker
chmod +x /usr/local/bin/docker
kekru / 1-Enable Docker Remote API with TLS client
Last active Oct 31, 2019
Docker Remote API with client verification via daemon.json
View 1-Enable Docker Remote API with TLS client

Enable Docker Remote API with TLS client verification

Docker's Remote API can be secured via TLS and client certificate verification.
First of all you need a few certificates and keys:

  • CA certificate
  • Server certificate
  • Server key
  • Client certificate
  • Client key

Create certificate files

kekru / 1.Docker Postgres
Last active Aug 15, 2017
Dockerized PostgreSQL with Pitrery
View 1.Docker Postgres

Postgres DB with point in time recovery with pitrery

Not yet tested


This image is based on docker's official postgres image. See here for usage information.
Remove or replace the timezone settings in this Dockerfile with your timezone. Currently "Europe/Berlin" is set.
The pitrery backup directory is /backup.

kekru / Springboot.Dockerfile
Last active Oct 29, 2019
Spring Boot Dockerfile template
View Springboot.Dockerfile
FROM openjdk:8-jre
RUN echo "Europe/Berlin" > /etc/timezone && dpkg-reconfigure -f noninteractive tzdata
RUN mkdir /data
ADD myapp.jar /data/myapp.jar
ENV springprofiles="" \
ENTRYPOINT MAXRAM=$(expr `cat /sys/fs/cgroup/memory/memory.limit_in_bytes` / 1024 / 1024) && \
View Simple FTP

Simple FTP based backup of a zip file

This script creates a zipfile and uploads it to an FTP server. You can define how many backups should be stored on the server. Older files will be deleted.

kekru / Windows
Last active Apr 12, 2017
Windows CMD Utilities
View Windows

Windows CMD Utilities

Search for string in files:

FINDSTR /spin "the string" *
Searches for "the string" in the files of the current and all subdirectories.

kekru / add CA cert on CentOS Debian
Last active Sep 30, 2019
Add CA cert to local trust store on CentOS, Debian or Ubuntu
View add CA cert on CentOS Debian
  • Open a webpage that uses the CA with Firefox
  • Click the lock-icon in the addressbar -> show information -> show certificate
  • the certificate viewer will open
  • click details and choose the certificate of the certificate-chain, you want to import to CentOS
  • click "Export..." and save it as .crt file
  • Copy the .crt file to /etc/pki/ca-trust/source/anchors on your CentOS machine
  • run update-ca-trust extract
  • test it with wget
View Dockerfile.oracledb.xe
# LICENSE CDDL 1.0 + GPL 2.0
# Copyright (c) 1982-2016 Oracle and/or its affiliates. All rights reserved.
# --------------------------
# This is the Dockerfile for Oracle Database 11g Release 2 Express Edition
# ----------------------------------
kekru / Vagrant create local
Last active Sep 10, 2019
Vagrant: Create local box
View Vagrant create local

Create box

This is how to install something in a VM and export it as a Vagrant box and use it locally.

First copy the Vagrantfile from below and change the box to the box you want as a base.

Run vagrant up to create the Virtual Machine and vagrant ssh to login.
On Windows you might have to put ssh.exe to your %PATH%. If you have installed git, you can use C:\Program Files\Git\usr\bin You can also login via Putty on host: "localhost", Port "2222", login: "vagrant", password: "vagrant".

You can’t perform that action at this time.