Skip to content

Instantly share code, notes, and snippets.

View bkmeneguello's full-sized avatar

Bruno Meneguello bkmeneguello

View GitHub Profile
@kellyrob99
kellyrob99 / jenkinsGroovyShell.groovy
Created February 26, 2012 01:09
Launch an interactive Groovy shell to a Jenkins server
@GrabResolver(name = 'glassfish', root = 'http://maven.glassfish.org/content/groups/public/')
@GrabResolver(name = "github", root = "http://kellyrob99.github.com/Jenkins-api-tour/repository")
@Grab('org.kar:hudson-api:0.2-SNAPSHOT')
@GrabExclude('org.codehaus.groovy:groovy')
import org.kar.hudson.api.cli.HudsonCliApi
/**
* Open an interactive Groovy shell that imports the hudson.model.* classes and exposes
* a 'hudson' and/or 'jenkins' object in the Binding which is an instance of hudson.model.Hudson
*/
HudsonCliApi cliApi = new HudsonCliApi()
@hsribei
hsribei / can-nat-traversal-be-tor-s-killer-feature.md
Last active July 12, 2018 19:15
Can NAT traversal be Tor's killer feature?

Can NAT traversal be Tor's killer feature?

tl;dr: how about a virtual global flat LAN that maps static IPs to onion addresses?

[We all know the story][1]. Random feature gets unintentionally picked up as the main reason for buying/using a certain product, despite the creator's intention being different or more general. (PC: spreadsheets; Internet: porn; smartphones: messaging.)

anonymous
anonymous / default.txt
Created December 3, 2017 12:33
Users and their passwords attempts
[0]
4
1
1 -
2 !
2 !@
1 &
1 0
3 0000
@mjbommar
mjbommar / r_oracle_jdbc_example1.R
Created November 22, 2012 15:36
Example of connecting to an Oracle database using R and RJDBC
# Set JAVA_HOME, set max. memory, and load rJava library
Sys.setenv(JAVA_HOME='/path/to/java_home')
options(java.parameters="-Xmx2g")
library(rJava)
# Output Java version
.jinit()
print(.jcall("java/lang/System", "S", "getProperty", "java.version"))
# Load RJDBC library
@sebkouba
sebkouba / gist:f2a982ea1c2b658574dcc3da8de09de6
Last active June 4, 2021 13:14 — forked from sunggun-yu/gist:4416430
Install NMON - CentOS 7 64bit
# Get Root
sudo su
# Download NMON archive
cd /tmp
wget http://sourceforge.net/projects/nmon/files/nmon16e_mpginc.tar.gz
# Untar archive
tar -xzvf nmon16e_mpginc.tar.gz
@Jiab77
Jiab77 / virt-manager.md
Last active August 12, 2021 23:04
Virt-Manager Installation (for ubuntu based distrib)

Virt-Manager Installation (for ubuntu based distrib)

This gist will give you all installation steps needed to install properly virt-manager with all dependencies.

Dependencies

Here is the list of all dependencies required to install properly virt-manager on your ubuntu based distrib.

  • libvirt-bin
  • qemu
@notheotherben
notheotherben / README.md
Last active September 9, 2021 07:50
Fix Postgres 9.x Sequences

PostgreSQL 9.x Sequence Fixing Script

This script is intended to automatically fix the sequence numbers for all tables in the current database.

This is accomplished through the use of the setval() command, which we provide with the next ID value we wish to make use of. We use the setval(sequence, number, is_called) overload and set is_called = false in conjunction with COALESCE(MAX + 1, 1) to ensure that, with an empty table, the next sequence value is 1 as expected.

@halberom
halberom / 00_description
Last active April 14, 2022 19:23
ansible - example of using filters to change each item in a list
The problem:
I wanted to use the jinja 'map' filter to modify each item in a string, in this simple
example, adding '.conf' to each item.
The 'format' filter in jinja takes arguments (value, *args, **kwargs). Unfortunately,
it uses 'value' as the pattern. When called inside map 'value' is the current item in
the list, or in other words *args as far as format is concerned. So it's the wrong way
around.
@hsw0
hsw0 / 000-README.md
Last active October 18, 2022 07:56
Samba AD + OpenSSH LPK Schema

Samba AD + openssh-lpk Schema

Add openssh-lpk Schema [1] to Samba 4 ad dc.

Usage

sed -i -e 's/${DOMAINDN}/DC=your,DC=domain,DC=name/' *.ldif'
@cocoalabs
cocoalabs / gist:2fb7dc2199b0d4bf160364b8e557eb66
Created August 15, 2016 21:50
Color Terminal for bash/zsh etc..
man() {
env \
LESS_TERMCAP_mb=$(printf "\e[1;31m") \
LESS_TERMCAP_md=$(printf "\e[1;31m") \
LESS_TERMCAP_me=$(printf "\e[0m") \
LESS_TERMCAP_se=$(printf "\e[0m") \
LESS_TERMCAP_so=$(printf "\e[1;44;33m") \
LESS_TERMCAP_ue=$(printf "\e[0m") \
LESS_TERMCAP_us=$(printf "\e[1;32m") \
man "$@"