Skip to content

Instantly share code, notes, and snippets.

Fernando Aleman fernandoaleman

  • Dallas, TX
Block or report user

Report or block fernandoaleman

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
fernandoaleman / nginx_init_script_centos
Created Oct 3, 2011
An Nginx init script for CentOS
View nginx_init_script_centos
# nginx - this script starts and stops the nginx daemin
# chkconfig: - 85 15
# description: Nginx is an HTTP(S) server, HTTP(S) reverse \
# proxy and IMAP/POP3 proxy server
# processname: nginx
# config: /opt/nginx/conf/nginx.conf
# pidfile: /opt/nginx/logs/
fernandoaleman /
Created Oct 3, 2011
How to install SSH Keys for authentication without password
# Create ssh private and public keys on your local machine
ssh-keygen -t rsa
# Set permissions on your private key
chmod 700 ~/.ssh
chmod 600 ~/.ssh/id_rsa
# Copy the public key to the server
scp ~/.ssh/
fernandoaleman / getversion
Created Oct 16, 2011
Show Mac OS Version
View getversion
module Tty extend self
def blue; bold 34; end
def white; bold 39; end
def red; underline 31; end
def reset; escape 0; end
def bold n; escape "1;#{n}" end
def underline n; escape "4;#{n}" end
def escape n; "\033[#{n}m" if STDOUT.tty? end
fernandoaleman /
Created Nov 18, 2011
How to sign your custom RPM package with GPG key
# How to sign your custom RPM package with GPG key
# Step: 1
# Generate gpg key pair (public key and private key)
# You will be prompted with a series of questions about encryption.
# Simply select the default values presented. You will also be asked
# to create a Real Name, Email Address and Comment (comment optional).
# If you get the following response:
fernandoaleman /
Created Nov 18, 2011
How to create an RPM from source with spec file
# How to create an RPM from source with spec file
# This is for Redhat versions of linux. Sometimes when you search for an rpm package,
# it is either outdated or not available. The only thing available is the source code.
# You can create a custom RPM package from source.
# For this example, I'll be using the latest version of Git, currently v.
# Step: 1
# Install rpmbuild
fernandoaleman /
Created Nov 18, 2011
Script to create rpm repository metadata
# This is for Redhat 64 bit versions of Linux with `createrepo` installed. If you
# do not have createrepo, you can install it with:
# yum install -y createrepo
# Change DESTDIR path to RPMS directory of your repo
for ARCH in x86_64
# How to create an RPM repository
# This is for Redhat 64 bit versions of Linux. You can create your own RPM repository # to host your custom RPM packages.
# See "How to create an RPM from source with spec file" for more information.
# Step: 1
# Install createrepo
View default.html
<!DOCTYPE html>
<meta charset="utf-8" />
<title>{{ page.title }}</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link href="/stylesheets/bootstrap.css" rel="stylesheet" />
<style type="text/css">
body {
padding-top: 60px;
fernandoaleman / Linux Static IP
Created Mar 23, 2012
How To Configure Static IP On CentOS 6
View Linux Static IP
## Configure eth0
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
fernandoaleman / Gemfile
Created May 8, 2012 — forked from simi/Gemfile
Refinery + Twitter Bootstrap WIP
View Gemfile
source ''
gem 'rails', '3.2.1'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://'
gem 'sqlite3'
You can’t perform that action at this time.