Skip to content

Instantly share code, notes, and snippets.

View bennythejudge's full-sized avatar

Benedetto Lo Giudice bennythejudge

View GitHub Profile
@bennythejudge
bennythejudge / jenkins-dump-credentials.groovy
Created March 30, 2022 11:22 — forked from timja/jenkins-dump-credentials.groovy
Dump jenkins credentials - use in script console
import com.cloudbees.plugins.credentials.*
import com.cloudbees.plugins.credentials.common.*
import com.cloudbees.plugins.credentials.domains.*
import com.cloudbees.plugins.credentials.impl.*
import com.cloudbees.jenkins.plugins.sshcredentials.impl.*
import org.jenkinsci.plugins.plaincredentials.impl.*
// def item = Jenkins.instance.getItem("your-folder")
@Tynael
Tynael / README.md
Last active October 9, 2024 22:42
How to use npx to run gist based scripts
# Split all objects and pass them to each filter below
# Create/Delete Namespace
(select(.verb == "create" and .objectRef.resource=="namespaces") |
"[" + .stageTimestamp + "] " + "Namespace Created: name=" + .objectRef.name),
(select(.verb == "delete" and .objectRef.resource=="namespaces") |
"[" + .stageTimestamp + "] " + "Namespace Deleted: name=" + .objectRef.name),
# Create/Delete Deployment
@lizrice
lizrice / Vagrantfile
Last active July 13, 2020 03:38
Preventative Kubernetes Security demo
# -*- mode: ruby -*-
# vi: set ft=ruby :
# After loading this
# Install a pod network
# $ kubectl apply -f https://cloud.weave.works/k8s/net?k8s-version=$(kubectl version | base64 | tr -d '\n')
# Allow pods to run on the master node
# $ kubectl taint nodes --all node-role.kubernetes.io/master-
@mattharrison
mattharrison / Pytest Intro Assignments.rst
Last active October 25, 2021 18:57
O'Reilly Pytest Class

Pytest Introduction

Copyright 2019 - Matt Harrison

@__mharrison__

@timja
timja / jenkins-dump-credentials.groovy
Last active August 8, 2024 09:55
Dump jenkins credentials - use in script console
import com.cloudbees.plugins.credentials.*
import com.cloudbees.plugins.credentials.common.*
import com.cloudbees.plugins.credentials.domains.*
import com.cloudbees.plugins.credentials.impl.*
import com.cloudbees.jenkins.plugins.sshcredentials.impl.*
import org.jenkinsci.plugins.plaincredentials.impl.*
// def item = Jenkins.instance.getItem("your-folder")
@davideschiera
davideschiera / readme.MD
Last active May 25, 2018 10:32
Sysdig Datasource Plugin for Grafana (beta)
@vaibhavkumar-sf
vaibhavkumar-sf / docker-compose.yml
Created January 29, 2018 11:39
docker-compose.yml STATIC IP assignment to all containers of a docker
version: "2"
services:
varnish:
#hostname: magento2.docker
image: meanbee/magento2-varnish:latest
environment:
- VIRTUAL_HOST=magento2.docker
- VIRTUAL_PORT=80
- HTTPS_METHOD=noredirect
ports:
@mateobur
mateobur / CloudFormationTemplateOpenShift.yaml
Created January 23, 2018 22:19
CloudFormation Template OpenShift
AWSTemplateFormatVersion: '2010-09-09'
Metadata: {}
Parameters:
###########
KeyName:
Description: The EC2 Key Pair to allow SSH access to the instance
Type: 'AWS::EC2::KeyPair::KeyName'
AvailabilityZone:
Description: Availability zone to deploy
@yoramvandevelde
yoramvandevelde / pipefail_examples.sh
Created August 17, 2017 07:13
Examples of why pipefail is really important to use
#!/bin/bash
# author: Yoram van de Velde ( [email protected] )
# Examples of why pipefail is really important to use.
# We enable exit on error functionality
set -o errexit
# These commands will fail but not stop the script because of the pipes
# to succesfull commands. This works because error is output to stderr,