apt-get install build-essential bzip2 libpcre3-dev libssl-dev mysql-server daemon libgeoip-dev
Download Nginx, Naxsi Core dan Naxsi UI. Saya berasumsi tempat download berada di /home/compile
# If you work with git, you've probably had that nagging sensation of not knowing what branch you are on. Worry no longer! | |
export PS1="\\w:\$(git branch 2>/dev/null | grep '^*' | colrm 1 2)\$ " | |
# This will change your prompt to display not only your working directory but also your current git branch, if you have one. Pretty nifty! | |
# ~/code/web:beta_directory$ git checkout master | |
# Switched to branch "master" | |
# ~/code/web:master$ git checkout beta_directory | |
# Switched to branch "beta_directory" |
# Put this in nrpe.cfg on the remote host you're monitoring. | |
command[check_load]=/usr/local/nagios/libexec/check_load -w 5,4,3 -c 10,8,6 | |
command[check_memory]=/usr/local/nagios/libexec/check_mem.pl -f -w 5 -c 2 | |
command[check_disk]=/usr/local/nagios/libexec/check_disk -w 20% -c 10% -p / | |
command[check_swap]=/usr/local/nagios/libexec/check_swap -w 20% -c 10% | |
command[check_zombie_procs]=/usr/local/nagios/libexec/check_procs -w 5 -c 10 -s Z | |
command[check_total_procs]=/usr/local/nagios/libexec/check_procs -w 150 -c 200 | |
command[check_users]=/usr/local/nagios/libexec/check_users -w 5 -c 10 |
#!/usr/bin/env ruby | |
# Display airtel broadband usage. Output format is | |
# airtel_id/quota GB/used GB/days_left | |
require 'rubygems' | |
require 'nokogiri' | |
require 'open-uri' | |
page = Nokogiri::HTML(open("http://122.160.230.125:8080/gbod/gb_on_demand.do", 'User-Agent' => 'curl/7.26.0', 'Accept' => "*/*")) |
<?php | |
add_filter( 'woocommerce_get_catalog_ordering_args', 'custom_woocommerce_get_catalog_ordering_args' ); | |
function custom_woocommerce_get_catalog_ordering_args( $args ) { | |
$orderby_value = isset( $_GET['orderby'] ) ? woocommerce_clean( $_GET['orderby'] ) : apply_filters( 'woocommerce_default_catalog_orderby', get_option( 'woocommerce_default_catalog_orderby' ) ); | |
if ( 'random_list' == $orderby_value ) { | |
$args['orderby'] = 'rand'; | |
$args['order'] = ''; |
add_filter( 'highwind_header_gravatar', '__return_false' ); |
add_action( 'highwind_site_title_link', 'jk_custom_header_image' ); | |
function jk_custom_header_image() { | |
?> | |
<img src="path/to/your/image.png" class="avatar" /> | |
<?php | |
} |
Create droplet of your liking (ubuntu 12.04 x32) Use an xx.04 LTS version
On Digital Ocean, create a DNS entry for your server (xyz.com)
Make sure it has NS records that use digital oceans nameservers
This should help you get Sendmail installed with basic configuration on Ubuntu.
sudo apt-get install sendmail
/etc/hosts
file: nano /etc/hosts
127.0.0.1 localhost yourhostname
sudo sendmailconfig
sudo service apache2 restart
<?php | |
// Place the following code in your theme's functions.php file to add the payment type to all emails | |
add_action( 'woocommerce_email_after_order_table', 'wc_add_payment_type_to_emails', 15, 2 ); | |
function wc_add_payment_type_to_emails( $order, $is_admin_email ) { | |
echo '<p><strong>Payment Type:</strong> ' . $order->payment_method_title . '</p>'; | |
} | |
// Place the following code in your theme's functions.php file to add the payment type to admin emails only | |
add_action( 'woocommerce_email_after_order_table', 'wc_add_payment_type_to_admin_emails', 15, 2 ); | |
function wc_add_payment_type_to_admin_emails( $order, $is_admin_email ) { |