Skip to content

Instantly share code, notes, and snippets.

https://github.com/IBM/grafana-mezmo-datasource without MANIFEST.txt
---
apiVersion: kyverno.io/v1
kind: ClusterPolicy
metadata:
name: replace-image-registry-docker
annotations:
pod-policies.kyverno.io/autogen-controllers: none
spec:
background: false
rules:
cat << EOF > config.bu
variant: fcos
version: 1.4.0
passwd:
users:
- name: sleeper
uid: 1001
storage:
links:
- path: /home/sleeper/.config/systemd/user/sockets.target.wants/podman.socket
helmDefaults:
wait: true
repositories:
- name: bitnami
url: https://charts.bitnami.com/bitnami
- name: dex
url: https://charts.dexidp.io
- name: dysnix
url: https://dysnix.github.io/charts
@lukasmrtvy
lukasmrtvy / main.tf
Created May 22, 2019 15:05
terraform: random_password
variable "password" { default = "" }
resource "random_string" "string" {
length = "12"
count = "${var.password == "" ? 1 : 0 }"
}
locals {
pwd = "${ element(concat(random_string.string.*.result, list("")), 0) != "" ? element(concat(random_string.string.*.result, list("")), 0) : var.password }"
- name: test
hosts: localhost
gather_facts: false
vars:
containers:
grafana:
variables:
docker:
foo1: "https://etcd/foo1"
---
- name: test
hosts: localhost
connection: local
gather_facts: no
vars:
containers:
grafana:
image: grafana/grafana:6.0.0
---
- name: test
hosts: localhost
connection: local
vars:
containers:
grafana:
image: grafana/grafana:6.0.0
ports: 3000:3000
@lukasmrtvy
lukasmrtvy / gist:dfd215f57995723096bce2e4222a2fe6
Created March 30, 2018 11:21 — forked from nmattam/gist:bcfbc8a4ebd9a520c2ac50ab0137e58f
[Splunk] Automate "Apply Changes" for Monitoring Console
# Create DMC groups
# This is basically updating the system/local/distsearch.conf
# I got all the IPs used below from /servicesNS/admin/-/search/distributed/peers. I used DNS names for search head (I had only one SH) and cluster master. So it was easy to separate the indexer IPs.
# 8089 is my API PORT
curl -k -u <user>:<password> <Monitoring Console>/services/search/distributed/groups -d name=dmc_group_search_head -d member=<search_head_member1:8089> -d member=<search_head_member2:8089> -d default=false
curl -k -u <user>:<password> <Monitoring Console>/services/search/distributed/groups -d name=dmc_group_cluster_master -d member=<cluster_master:8089> -d default=false
curl -k -u <user>:<password> <Monitoring Console>/services/search/distributed/groups -d name=dmc_group_indexer -d member=<indexer1:8089> -d member=<indexer2:8089> -d default=true # not idea why default=true for indexers
curl -k -u <user>:<password> <Monitoring Console>/services/search/distributed/groups -d name=dmc_indexerclustergroup_<CLUSTER_L
@lukasmrtvy
lukasmrtvy / index.php
Created November 29, 2015 21:34 — forked from Skalman/index.php
Dynamic RSS feeds from Youtube links
<?php
if (!isset($_GET['url'])) {
?>
<!DOCTYPE html>
<meta charset="utf-8">
<title>Youtube RSS creator</title>
<form>
<p>Create an RSS feed for the videos on the following page:
<p><input name="url" placeholder="E.g. https://www.youtube.com/user/scishow/videos" style="width: 30em">