Skip to content

Instantly share code, notes, and snippets.

@arthurzenika
arthurzenika / pod.yaml
Created September 24, 2020 09:00
kubectl get pod/certinfo-647757965d-nm4df -n openfaas-fn -o yaml
apiVersion: v1
kind: Pod
metadata:
annotations:
kubernetes.io/limit-ranger: 'LimitRanger plugin set: cpu, memory request for container
certinfo; cpu, memory limit for container certinfo'
prometheus.io.scrape: "false"
creationTimestamp: "2020-09-24T08:56:34Z"
generateName: certinfo-647757965d-
labels:
@arthurzenika
arthurzenika / openpgp.md
Last active August 25, 2020 10:55
openpgp.md
<!doctype html>
<html>
<head>
<title>Example Domain</title>
<meta charset="utf-8" />
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style type="text/css">
body {
def event_return(events):
'''
Return event data to remote carbon server
Provide a list of events to be stored in carbon
'''
opts = _get_options({}) # Pass in empty ret, since this is a list of events
opts['skip'] = True
for event in events:
@arthurzenika
arthurzenika / gist:7b132720ab6b8b728e79
Created November 6, 2014 09:23
/etc/apache2/sites-available/openstack-dashboard-ssl-redirect.conf
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
<Directory />
AllowOverride None
</Directory>
RewriteEngine On
RewriteCond %{HTTPS} off
@arthurzenika
arthurzenika / poodlebleed.sls
Created October 15, 2014 09:22
poodlebleed.sls for saltstack deploymenet of poodel vulnerability in SSLv3
{% if salt['pkg.version']('apache2') %}
poodle apache server restart:
service.running:
- name: apache2
{% for foundfile in salt['cmd.run']('rgrep -m 1 SSLProtocol /etc/apache*').split('\n') %}
{% if 'No such file' not in foundfile and 'bak' not in foundfile and foundfile.strip() != ''%}
poodle {{ foundfile.split(':')[0] }}:
file.replace:
- name : {{ foundfile.split(':')[0] }}
- pattern: "SSLProtocol all -SSLv2[ ]*$"
#!/bin/bash
# ------------------------------------------------------------------------------
# SOME INFOS : fairly standard (debian) init script.
# Note that node doesn't create a PID file (hence --make-pidfile)
# has to be run in the background (hence --background)
# and NOT as root (hence --chuid)
#
# MORE INFOS : INIT SCRIPT http://www.debian.org/doc/debian-policy/ch-opersys.html#s-sysvinit
# INIT-INFO RULES http://wiki.debian.org/LSBInitScripts
# INSTALL/REMOVE http://www.debian-administration.org/articles/28