Skip to content

Instantly share code, notes, and snippets.

View luebken's full-sized avatar

Matthias Lübken luebken

View GitHub Profile
@luebken
luebken / fetch_subtitles.sh
Created April 22, 2023 14:32 — forked from teemow/fetch_subtitles.sh
fetch youtube playlist with title, description and subtitles of each video and train gpt with the information
#!/bin/bash
set -eu
FOLDER=$1
PLAYLIST=$2
rm -f playlist.txt
mkdir -p $FOLDER
yt-dlp --flat-playlist -i --print-to-file url playlist.txt $PLAYLIST
const { PrometheusExporter } = require('@opentelemetry/exporter-prometheus');
const { MeterProvider } = require('@opentelemetry/metrics');
const { Resource } = require('@opentelemetry/resources');
// Add your port and startServer to the Prometheus options
const options = {port: 9464, startServer: true};
const exporter = new PrometheusExporter(options);
@luebken
luebken / CKAD-Exam.md
Last active August 23, 2019 22:41
Resources to learn for the CKAD Exam
@luebken
luebken / expose-k8s-service.md
Created March 12, 2018 22:17
Create a svc from a docker image, expose it, curl it.

Task: Create a svc from a docker image, expose it, curl it.

Minikube:

# 1) start local k8s
$ minikube start --kubernetes-version=v1.7.5 --vm-driver hyperkit
...
$ kubectl get pods,svc,deployment
NAME             TYPE        CLUSTER-IP   EXTERNAL-IP   PORT(S)   AGE
svc/kubernetes ClusterIP 10.0.0.1  443/TCP 1m
{
"main": {
"name": "express",
"ecosystem": "npm",
"repository": "https://github.com/expressjs/express"
},
"librariesio": {
"name": "express",
"platform": "NPM",
"description": "Fast, unopinionated, minimalist web framework",
@luebken
luebken / getting_back_into_js_dev.md
Created June 21, 2017 08:08
Getting (back) into JavaScript development

Getting (back) into JavaScript development

Lately I came back into Javascript development. Although my preferred language is still Go there is the undeniable fact that JavaScript is a tool used by many modern platforms. As per request by Mr. Goern here are my lessons learned. Please comment and fill in.

General setup

I’m on a Mac and use iTerm and VSCode. I’m not going to argue about these choices.

Setup ESLint

oc login -u system:admin
cat <<-EOF > /Users/mdl/tmp/pv.yaml
apiVersion: v1
kind: PersistentVolume
metadata:
name: pv0001
spec:
capacity:
storage: 1Gi
@luebken
luebken / openshift.md
Last active November 21, 2016 23:43
Getting started with OpenShift
oc new-project mdl
oc new-build https://github.com/openshift-s2i/s2i-aspnet
oc new-app sabre1041/s2i-aspnet~https://github.com/openshift-s2i/s2i-aspnet-example --context-dir=app --name=aspnet-app
oc expose service aspnet-app
export OPENSHIFT_DEV_CLUSTER=true
export OPENSHIFT_NUM_MINIONS=1
vagrant up
Bringing machine 'master' up with 'virtualbox' provider...
Bringing machine 'minion-1' up with 'virtualbox' provider...
==> master: Importing base box 'fedora_deps'...
==> master: Matching MAC address for NAT networking...
==> master: Setting the name of the VM: origin_master_1467065804327_11350
==> master: Fixed port collision for 22 => 2222. Now on port 2200.