Skip to content

Instantly share code, notes, and snippets.

View schliflo's full-sized avatar
💻
🤔💭🔥

Florian Schlittenbauer schliflo

💻
🤔💭🔥
View GitHub Profile
__..-----')
,.--._ .-'_..--...-'
'-"'. _/_ / ..--''""'-.
_.--""...:._:(_ ..:"::. \
.-' ..::--""_(##)#)"':. \ \) \ _|_ /
/_:-:'/ :__(##)##) ): ) '-./' '\.-'
" / | :' :/""\///) /:.' --( )--
/ :( :( :( (#//) " .-'\.___./'-.
/ :/|\ :\_:\ \#//\ / | \
@schliflo
schliflo / nginx-ispconfig-bedrock.conf
Created March 6, 2019 17:23
wordpress bedrock ispconfig nginx config
##subroot bedrock/web ##
client_max_body_size 256M;
gzip on;
gzip_http_version 1.1;
gzip_vary on;
gzip_comp_level 6;
gzip_proxied any;
gzip_types text/plain text/html text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript application/javascript text/x-js;
@schliflo
schliflo / .gitignore_global
Created November 26, 2018 14:10
global gitignore
# Node
npm-debug.log
# Mac
.DS_Store
# Windows
Thumbs.db
# IntelliJ
@schliflo
schliflo / rsync-ipsec-deploy.sh
Created November 19, 2018 13:08
rsync deploy via ipsec VPN
# PROJECT SPECIFIC
export DEPLOY_SERVER="SERVER_IP"
export DEPLOY_USER="SSH_USER"
export DEPLOY_PASS="SSH_PASS"
export DEPLOY_DIR="DEPOY_PATH"
export DEPLOY_PORT="22"
export DEPLOY_VPN_USR="VPN_USR"
export DEPLOY_VPN_PASS="VPN_PASS"
export DEPLOY_VPN_URL="VPN_URL"
# GENERAL
@schliflo
schliflo / smooth-scroll.js
Created January 22, 2018 09:54
Smooth scrolling
'use strict';
/*
This is a dependency free drop-in solution for smooth anchor scrolling.
It was largely inspired by this answer: https://stackoverflow.com/questions/17722497/scroll-smoothly-to-specific-element-on-page#answer-39494245
Added support for changing documents and excluding anchors with .no-scroll class as well as browser history
*/
(function () {
let anchors;
@schliflo
schliflo / sunrise.php.patch
Created November 3, 2017 16:13
Add sunrise.php via composer patch for bedrock based environments
diff --git a/wp-content/sunrise.php b/wp-content/sunrise.php
new file mode 100644
index 00000000..dcefbb0c
--- /dev/null
+++ b/wp-content/sunrise.php
@@ -0,0 +1,37 @@
+<?php
+if ( !defined( 'SUNRISE_LOADED' ) )
+ define( 'SUNRISE_LOADED', 1 );
+
@schliflo
schliflo / do.sh
Created September 7, 2017 09:09
bash one-liner to find the nearest DigitalOcean data center
for DC in nyc1 nyc2 nyc3 ams2 ams3 sfo1 sfo2 sgp1 lon1 fra1 tor1 blr1; do echo "$DC: $(ping -i .1 -c 100 -q speedtest-$DC.digitalocean.com | awk -F/ '/^round|^rtt/{print $5}')"; done | sort -n -k2
@schliflo
schliflo / docker-compose.yml
Last active June 3, 2020 20:10
Docker compose plex letsencrypt proxy setup
# /opt/docker-compose.yml
---
version: '2'
services:
proxy:
image: jwilder/nginx-proxy
container_name: proxy
ports:
- "80:80"
- "443:443"
@schliflo
schliflo / main.js
Last active April 22, 2017 10:35
Random changing background image from a json list of image urls
const body = document.querySelector('body');
const imageBasePath = 'images/Photobox/';
const imageListFile = 'images.json';
const updateInterval = 1000;
let lastUpdated = 0;
let images = [];
let imagesInDoc = [];
function updateImageList(callback) {
let request = new XMLHttpRequest();
@schliflo
schliflo / keybase.md
Created March 15, 2017 10:47
keybase.md

Keybase proof

I hereby claim:

  • I am schliflo on github.
  • I am schliflo (https://keybase.io/schliflo) on keybase.
  • I have a public key whose fingerprint is C36A 9F08 F2F5 CED4 89DE 1ACB CDA7 3BCD 5A51 0303

To claim this, I am signing this object: