Skip to content

Instantly share code, notes, and snippets.

View richistron's full-sized avatar
:octocat:
Coding like a baws

Ricardo Rivas richistron

:octocat:
Coding like a baws
View GitHub Profile
@richistron
richistron / tcp-dump.sh
Created February 8, 2022 20:53 — forked from scalopus/tcp-dump.sh
TCPDump: Monitoring `locahost` for Graylog, statsd, fluentd (MacOS)
sudo tcpdump -A -s0 -ilo0 port 24224 or port 12201 or port 8125
@richistron
richistron / gist:c613e49801b314972db58467ed36b498
Created May 13, 2021 04:58 — forked from szydan/gist:b225749445b3602083ed
<U+FEFF> character showing up in files. How to remove them?
1) In your terminal, open the file using vim:
vim file_name
2) Remove all BOM characters:
:set nobomb
3) Save the file:
:wq
@richistron
richistron / generate-ssh-key.sh
Created November 4, 2019 15:53 — forked from grenade/01-generate-ed25519-ssh-key.sh
Correct file permissions for ssh keys and config.
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/id_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/github_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/mozilla_rsa
@richistron
richistron / gist:f4458ae5d810ef24406a3a298c16fc72
Created January 6, 2017 23:43 — forked from sl4m/gist:5091803
create self-signed certificate for localhost
# SSL self signed localhost for rails start to finish, no red warnings.
# 1) Create your private key (any password will do, we remove it below)
$ openssl genrsa -des3 -out server.orig.key 2048
# 2) Remove the password
$ openssl rsa -in server.orig.key -out server.key
@richistron
richistron / nginxproxy.md
Created July 7, 2016 17:59 — forked from soheilhy/nginxproxy.md
How to proxy web apps using nginx?

Virtual Hosts on nginx (CSC309)

When hosting our web applications, we often have one public IP address (i.e., an IP address visible to the outside world) using which we want to host multiple web apps. For example, one may wants to host three different web apps respectively for example1.com, example2.com, and example1.com/images on the same machine using a single IP address.

How can we do that? Well, the good news is Internet browsers