Skip to content

Instantly share code, notes, and snippets.

dlaxar / Install newer ruby version (>= 1.9)
Created Jun 26, 2012
Installing Redmine AND GitLab on CentOS 6.2 (part 2)
View Install newer ruby version (>= 1.9)
curl -O
tar xzvf ruby-1.9.3-p0.tar.gz
cd ruby-1.9.3-p0
./configure --enable-shared --disable-pthread --program-suffix n
make && make install
predominant /
Created Oct 5, 2011
Install Ubuntu 11.04 Nginx based web server with PHP-FPM, MySQL and MongoDB
# Copyright (c) 2011 Cake Development Corporation (
# Ubuntu 11.04 based web server installation script
# Run this by executing the following from a fresh install of Ubuntu 11.04 server:
# bash -c "$(curl -fsSL" <mysqlPassword>
wsargent / gist:1258640
Created Oct 3, 2011
Setting up a base vagrant box for Oracle
View gist:1258640
Install instructions for 10.2:
[Required files]
basuke / gen-security.php
Created Apr 20, 2011
Generate CakePHP configuration value for security, Security.salt and Security.cipherSeed.
View gen-security.php
$salt = genrandom(40);
$seed = genrandom(29, "0123456789");
echo "\tConfigure::write('Security.salt', '$salt');\n";
echo "\tConfigure::write('Security.cipherSeed', '$seed');\n";
function genrandom($len, $salt = null) {
if (empty($salt)) {
# curl headers
curl -Iv
# check certificate
openssl s_client -connect
# Remove Mac OS X Desktop Services Store files
find . -name ".DS_Store" -exec rm {} \;
# If you accidentally chmod -R 755 on everything revert files to 644
dlaxar / a. Add the epel repo to yum
Created Jun 26, 2012
Installing Redmine AND GitLab on CentOS 6.2 (part 1)
View a. Add the epel repo to yum
rpm -Uvh
nrollr /
Last active Mar 28, 2018
Ruby and Rails on El Capitan

#Install Ruby and Rails on El Capitan The following procedure was used to install the required components on El Capitan (clean install)

First make sure Xcode Command Line Tools are installed.
Open Terminal and enter: xcode-select --install you will be prompted to start the installation. Once finished proceed..

##Install Homebrew Important Notice: Homebrew and El Capitan, make sure to read the article!

  • Enter the following command: ruby -e "$(curl -fsSL"
morgant / compress_and_encrypt-no_exposed_password.txt
Last active Jul 10, 2018
Compress & Encrypt to Disk Using OpenSSL in Bash Without Exposing Password
View compress_and_encrypt-no_exposed_password.txt
# This is the simplest and cleanest way I've come up with for securely compressing (gzip, in this example) & encrypting data to disk with OpenSSL from a bash script without exposing the password to inspection of process or environment variable using `ps` and the likes. Naturally, `cat` is just used as an example so the data can come from anywhere. If the compressed data is to be sent via email instead of written to disk, don't use '-out' and use '-a' to base64 encode the compressed data.
# References:
cat "$file" | gzip -c | openssl enc -e -salt -aes-256-cbc -pass fd:3 -out "$file.gz.enc" 3<<<"$password"
kwharrigan /
Created Apr 12, 2012
MKS fast-import script for git
#Copyright (c) 2012 Kyle Harrigan
#Permission is hereby granted, free of charge, to any person obtaining a copy
#of this software and associated documentation files (the "Software"), to deal
#in the Software without restriction, including without limitation the rights
#to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
#copies of the Software, and to permit persons to whom the Software is
#furnished to do so, subject to the following conditions:
View Dockerfile.tmpl
# using VirtualBox version $VBOX_VERSION
FROM boot2docker/boot2docker
RUN apt-get install p7zip-full
RUN mkdir -p /vboxguest && \
cd /vboxguest && \
curl -L -o vboxguest.iso$VBOX_VERSION/VBoxGuestAdditions_$VBOX_VERSION.iso && \
7z x vboxguest.iso -ir'!' && \
sh --noexec --target . && \