This blog post shows how to create a token:
Enable developer mode:
- User Settings
- Advanced
- Enable Developer Mode
Get the channel id:
This blog post shows how to create a token:
Enable developer mode:
Get the channel id:
<!doctype html> | |
<title>Site Maintenance</title> | |
<style> | |
body { text-align: center; padding: 150px; } | |
h1 { font-size: 50px; } | |
body { font: 20px Helvetica, sans-serif; color: #333; } | |
article { display: block; text-align: left; width: 650px; margin: 0 auto; } | |
a { color: #dc8100; text-decoration: none; } | |
a:hover { color: #333; text-decoration: none; } | |
</style> |
import socket | |
def find_open_port(): | |
""" | |
Use socket's built in ability to find an open port. | |
""" | |
sock = socket.socket() | |
sock.bind(('', 0)) |
######################################################## | |
# How To Auto-Scale Kubernetes Clusters With Karpenter # | |
# https://youtu.be/C-2v7HT-uSA # | |
######################################################## | |
# Referenced videos: | |
# - GKE Autopilot - Fully Managed Kubernetes Service From Google: https://youtu.be/Zztufl4mFQ4 | |
######### | |
# Setup # |
Access Log:
172.16.4.86 - - [04/Jun/2022:07:58:38 +0000] "GET / HTTP/2.0" 301 280 "-" "curl"
Query in Grafana / Loki:
{job="prod/nginx"} |= "GET / "
Using a standard prometheus config to scrape two targets:
ip-192-168-64-29.multipass:9100
ip-192-168-64-30.multipass:9100
global:
scrape_interval: 15s
evaluation_interval: 15s
#!/usr/bin/env python3 | |
# docs: https://grafana.com/docs/loki/latest/api/#post-lokiapiv1push | |
import requests | |
import time | |
# variables | |
LOKI_USERNAME="x" | |
LOKI_PASSWORD="x" | |
LOKI_ENDPOINT="https://loki-api.example.com/loki/api/v1/push" |
This is a basic example with a dirty bash script on how to create a copy of a production database and update the column values of the new (test / staged) database, which might be sensitive or which is not suitable for test environments.
This test is intentional for small datasets.
The flow:
#!/usr/bin/env bash | |
export GOVERSION="1.17.2" | |
export GETHVERSION="1.10.9" | |
apt update | |
apt install wget tar locales-all -y | |
touch /var/lib/cloud/instance/locale-check.skip | |
mkdir -p /blockchain/ethereum/data | |
mkdir -p /usr/local/geth/${GETHVERSION}/bin |
Sending SMS's with AWS SNS:
import boto3
sms_number='+27000000000'
sns = boto3.Session(profile_name='default', region_name='eu-west-1').client('sns')
response = sns.publish(
PhoneNumber=sms_number,