Inspired By: grafana/loki#333
- docker-compose.yml
version: "3"
networks:
loki:
#!/bin/ash | |
# Usage: cat /id_token.txt | jwt-decode.sh --no-verify-sig" > jwt_payload.json | |
. /usr/share/libubox/jshn.sh | |
base64_padding() | |
{ | |
local len=$(( ${#1} % 4 )) | |
local padded_b64='' | |
if [ ${len} = 2 ]; then | |
padded_b64="${1}==" |
#!/bin/sh | |
# Decode a JWT from stdin and verify it's signature with the JWT issuer public key | |
# Only RS256 keys are supported for signature check | |
# | |
# Put OAuth server public key in PEM format to /var/cache/oauth/$JWT_KID.key.pub.pem | |
# You must create the folder first | |
# $ sudo mkdir -p /var/cache/oauth/ | |
# To converted key from JWK to PEM use https://8gwifi.org/jwkconvertfunctions.jsp or https://keytool.online/ | |
# NOTE: For Google you can get the keys in PEM format via https://www.googleapis.com/oauth2/v1/certs | |
# Decode the keys with decodeURIComponent() |
1) create a file squid.conf | |
``` | |
acl denydomain dstdomain .bbc.com | |
http_access deny denydomain | |
acl allowdomain dstdomain .yahoo.com | |
http_access allow allowdomain | |
http_access deny all |
Inspired By: grafana/loki#333
version: "3"
networks:
loki:
#!/usr/bin/env bash | |
# https://gist.github.com/gretel/34008d667a8a243a9682e5207619ad95 | |
# 2016 tom hensel <[email protected]> | |
# `vagrant` on `ubuntu-16.04` can get in conflict with *unattended-upgrade* running and locking the `dpkg` subsystem. this script waits gracefully | |
# in `Vagrantfile`: | |
# config.vm.provision 'Wait for unattended-upgrades', type: 'shell', path: './provisioning/wait_unattended_upgrades.sh', args: %w( dpkg apt unattended-upgrade ) | |
# | |
function wait_procnames { | |
while true; do |