Skip to content

Instantly share code, notes, and snippets.

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: external-secrets
# namespace: foo
rules:
- apiGroups: [""]
resources:
- secrets
verbs:
<!DOCTYPE html>
<html>
<body>
<div id="terminal"
style="position:relative; width:100%; height:500px"></div>
</body>
<script src="hterm_all.js"></script>
<script>
hterm.defaultStorage = new lib.Storage.Local()
<!DOCTYPE html>
<html>
<body>
<div id="terminal"
style="position:relative; width:100%; height:500px"></div>
</body>
<script src="hterm_all.js"></script>
<script>
hterm.defaultStorage = new lib.Storage.Local()
diff --git a/pkgs/build-support/rust/default.nix b/pkgs/build-support/rust/default.nix
index 79e4366..aa90c23 100644
--- a/pkgs/build-support/rust/default.nix
+++ b/pkgs/build-support/rust/default.nix
@@ -26,6 +26,8 @@ in stdenv.mkDerivation (args // {
configurePhase = args.configurePhase or "true";
+ unpackPhase = args.unpackPhase or "unpackPhase";
+
@jgillich
jgillich / rendering_hack.rb
Created October 12, 2015 16:02
Hack for Middleman, allows usage of erb in markdown files without the .erb extension.
module Middleman
module CoreExtensions
module Rendering
# Rendering instance methods
module InstanceMethods
def _render_with_all_renderers(path, locs, context, opts, &block)
# Keep rendering template until we've used up all extensions. This
# handles cases like `style.css.sass.erb`
content = nil
sudo yum install http://download.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm
sudo yum install @development qemu qemu-kvm libvirt libvirt-python wget man python-pip sqlite-devel libxml2-python libxml2-devel libxslt-devel
sudo systemctl enable libvirtd
sudo systemctl start libvirtd
sudo echo '[Remote libvirt SSH access]
Identity=unix-user:virtkick
Action=org.libvirt.unix.manage
ResultAny=yes
ResultInactive=yes
# API Usage
RatticDB include an API that you an use to programatically acces the data you have stored. Currently the API only supports read access for credential, however we expect this to change at time progresses.
## Authentication
To authenticate to RatticDB you can choose to use either session authentication, or API Key authentication. Sessions keys require a user to have logged in with their username, password and if configured their one time pad device. API keys on the other hand are static values that are designed for systems that may not have interactive access.
To use the session based authentication simply use your browser to log into RatticDB and then browse to the API endpoints. Because the Accept header cannot usually be controlled in most web browsers you need to provide a hint as to the format of the request via the query string. So for example if you wanted to hit the `/api/v1/cred/1/` endpoint and get JSON data returned you would append `?format=json` which would make the URL be `/api/v1/
# yum update
Loaded plugins: fastestmirror
base | 3.6 kB 00:00:00
epel/x86_64/metalink | 26 kB 00:00:00
epel | 3.7 kB 00:00:00
extras | 3.3 kB 00:00:00
updates | 3.4 kB 00:00:00
(1/6): base/7/x86_64/group_gz | 157 kB 00:00:00
(2/6): epel/x86_64/group_gz | 163 kB 00:00:00
updates/7/x86_64/primary_db FAILED
@jgillich
jgillich / js.py
Last active August 29, 2015 14:05
# -*- coding: utf-8 -*-
'''
JavaScript Renderer for Salt
Example SLS file:
#!js
module.exports.wget = function () {
return { pkg: ['installed'] };
@jgillich
jgillich / handlebars.localisation.js
Last active January 4, 2016 16:49
Handlebars localisation helper, inspired by https://gist.github.com/tracend/3261055
Handlebars.registerHelper('loc', function(keyword) {
var lang = navigator.language || navigator.userLanguage;
// If lang is not found, try without subtag and fall back to en
lang = locale[lang] || (lang.indexOf('-') !== -1 && locale[lang.split('-')[0]]) || locale['en'] ;
return lang && _.template('<%= ' + keyword + ' %>', lang) || keyword;
/* without underscore
var keys = keyword.split(".");
for (var i in keys) {