Skip to content

Instantly share code, notes, and snippets.

View aabenitez's full-sized avatar

Alcides Benitez aabenitez

View GitHub Profile
@EugenMayer
EugenMayer / msys_hetzner-etc_network_interfaces
Created May 20, 2017 21:57 — forked from jpawlowski/msys_hetzner-etc_network_interfaces
Debian network configuration for Proxmox VE server running on a Hetzner host
# /etc/network/interfaces
#
auto lo
iface lo inet loopback
# device: eth0
iface eth0 inet manual
# IPv4 bridge
# (connect ONLY your firewall/router KVM instance here, this is the WAN device!)
@mandiwise
mandiwise / Update remote repo
Last active May 2, 2024 08:59
Transfer repo from Bitbucket to Github
// Reference: http://www.blackdogfoundry.com/blog/moving-repository-from-bitbucket-to-github/
// See also: http://www.paulund.co.uk/change-url-of-git-repository
$ cd $HOME/Code/repo-directory
$ git remote rename origin bitbucket
$ git remote add origin https://github.com/mandiwise/awesome-new-repo.git
$ git push origin master
$ git remote rm bitbucket
@hongquan
hongquan / turnon_usb3g.sh
Created April 17, 2014 17:57
Script to switch USB 3G to modem
#!/bin/sh
if ! $(lsusb | grep E173 > /dev/null); then
echo 'Device not plugged'
exit
fi
if $(usb-devices | grep 'Driver=option' > /dev/null); then
echo 'Modem mode has been on'
exit
fi
@andrewflash
andrewflash / php_mailer.php
Created November 23, 2013 05:32
Using PHP Mailer to Send HTML Emails with Images
<?php
require("class.phpmailer.php");
$mail = new PHPMailer();$mail = new PHPMailer();
$mail->IsSMTP();
$mail->Host = "smtp1.example.com;smtp2.example.com";
$mail->SMTPAuth = true;
$mail->Username = 'smtpusername';
$mail->Password = 'smtppassword';
$mail->From="mailer@example.com";
@kjellski
kjellski / sshd_config
Created July 6, 2013 18:59
This is an example real-world sshd_config with a nice little example at the end. A match clause that enables different setting for specific ranges than general settings...
# This is the sshd server system-wide configuration file. See
# sshd_config(5) for more information.
# This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin
# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented. Uncommented options change a
# default value.