Skip to content

Instantly share code, notes, and snippets.

View konstan's full-sized avatar
🎯
Focusing

Konstantin Skaburskas konstan

🎯
Focusing
View GitHub Profile
@konstan
konstan / gist:ebcc78ece247a6febc3d1da8176b04c5
Created May 28, 2024 07:36
Roles and ClusterRoles definitions for NuvlaEdge (experiment)
ROLES_MANIFEST = '''
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
namespace: {namespace}
name: serviceaccount-getter
rules:
- apiGroups: [""]
resources: ["*"]
@konstan
konstan / helm-install-Ubuntu.sh
Created February 6, 2022 16:13
Install Helm on Ubuntu
#!/usr/bin/env bash
set -ex
curl https://baltocdn.com/helm/signing.asc | sudo apt-key add -
sudo apt-get install apt-transport-https --yes
echo "deb https://baltocdn.com/helm/stable/debian/ all main" | sudo tee /etc/apt/sources.list.d/helm-stable-debian.list
sudo apt-get update
sudo apt-get install helm
@konstan
konstan / docker-install-Ubuntu.sh
Created February 6, 2022 15:47
Install docker on Ubuntu
#!/bin/bash -ex
apt-get update
apt-get remove -y \
docker \
docker-engine \
docker.io \
containerd \
runc || true
apt-get install -y \
@konstan
konstan / k3d_rancher.sh
Last active February 6, 2022 19:40 — forked from jwsy/k3d_rancher.sh
Create a k8s cluster and install Rancher with k3d and Helm
#!/bin/bash -x
echo Set localhost or public IP.
echo 1
HOSTNAME=rancher.k3d.localhost
HOSTNAME=rancher.$(ip a s eth0 | awk '/inet / {print $2}' | sed -e 's|/.*||').nip.io
### 1. Create a cluster with k3d that connects port 443 to the loadbalancer provided by k3d
k3d cluster create k3d-rancher --api-port 6550 --servers 1 --agents 3 --port 443:443@loadbalancer --wait
k3d cluster list
@konstan
konstan / gist:45fcd0e29996ef401939b97590a97317
Created January 4, 2017 08:17
Grok pattern for Restlet log to be used with logstash
# Grok pattern for Restlet log entry. Only for the first 14 fields.
#
# 1. Date (YYYY-MM-DD)
# 2. Time (HH:MM:SS)
# 3. Client address (IP)
# 4. Remote user identifier (see RFC 1413)
# 5. Server address (IP)
# 6. Server port
# 7. Method (GET|POST|...)
# 8. Resource reference path (including the leading slash)