What is easy | hard to alter
What can be done to make the hard stuff easier to alter
What is worth altering
What can go
What is the benefit of making a change
What is easy | hard to alter
What can be done to make the hard stuff easier to alter
What is worth altering
What can go
What is the benefit of making a change
-- Make sure you pick somewhere you | |
-- have permissions to write to. | |
SET GLOBAL GENERAL_LOG = 'off'; | |
SET GLOBAL GENERAL_LOG_FILE = '/Users/lloyd/mysql.log'; | |
SET GLOBAL GENERAL_LOG = 'on'; |
#!/bin/sh | |
cd /var/www/site-staging && git reset --hard && git pull -f origin staging | |
echo ok |
server { | |
index index.php; | |
set $base "/var/www"; | |
set $domain $host; | |
# Simple | |
if ($domain ~ "^(.[^.]*)\.loc$") { | |
set $domain $1; | |
set $rootpath "${domain}"; | |
set $servername "${domain}.loc"; |
import boto | |
from pprint import pprint | |
ec2 = boto.connect_ec2() | |
instances = [x for y in ec2.get_all_instances() for x in y.instances] | |
for x in instances: | |
pprint(x.__dict__) | |
<?php | |
namespace API\Service\Command; | |
use API\Service\CommandService; | |
class ContentCommandService extends CommandService | |
{ | |
protected $hasMany = 'Asset'; | |
protected $uses = 'ContentMapping'; |
There are a lot of articles exploring the whys and wherefores of redis and I thought I would share some thoughts from somebody well versed in redis having used it in production over the past five or six years.
One of the foundations of the power of relational databases is the use of indexes. Redis gives you the ability to build your own, the way you want it, in a completely visible manner.
from base64 import decodestring | |
print decodestring("SSBhbSB0aGUgc29mdHdhcmUgZ2FyZGVuZXIsIHRoZSBjdWx0aXZhdG9yIG9mIGRpZ2l0YWwgcGxhbnRzIGFuZCB0aGUgbW93ZXIgb2YgY29kZWQgc2VlZHM=/n") |
{ | |
"AWSTemplateFormatVersion": "2010-09-09", | |
"Description": "CloudFormation template: VPC, subnets(public, private), NAT for private network Internet access", | |
"Parameters": { | |
"KeyPairName": { | |
"Description": "A key pair name", | |
"Type": "String", |