To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.
- Homebrew
- Mountain Lion -> High Sierra
cd ~ | |
sudo apt-get update | |
sudo apt-get install openjdk-7-jre-headless -y | |
# Download the compiled elasticsearch rather than the source. | |
wget http://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.20.2.tar.gz -O elasticsearch.tar.gz | |
tar -xf elasticsearch.tar.gz | |
rm elasticsearch.tar.gz | |
sudo mv elasticsearch-* elasticsearch | |
sudo mv elasticsearch /usr/local/share |
var rootWin = Ti.UI.createWindow(); | |
var navGroup = Ti.UI.iPhone.createNavigationGroup({ | |
window: rootWin | |
}); | |
var button = Ti.UI.createButton({ | |
title: 'Open ListView Tests' | |
}); | |
button.addEventListener('click', function() { | |
openTestsWindow(); | |
}); |
# for real, I have a mapping and my color is not "indexed" | |
curl -XPUT 'http://localhost:9200/pony_index_tmp' -d ' | |
{ | |
settings: { | |
number_of_shards: 1, | |
number_of_replicas: 0 | |
} | |
}' | |
curl -XPOST "http://localhost:9200/pony_index_tmp/pony/1" -d ' |
<?php | |
if (Config::has('sentry.key')) { | |
$bufferHandler = new Monolog\Handler\BufferHandler( | |
new Monolog\Handler\RavenHandler( | |
new Raven_Client(Config::get('sentry.key')), | |
Monolog\Logger::WARNING | |
) | |
); | |
1. Drop all incoming connections to ElasticSearch on port 9200: | |
iptables -A INPUT -j DROP -p tcp --destination-port 9200 -i eth0 | |
2. Persist this change on reboot: | |
iptables-save > /root/my_iptables_config | |
/sbin/iptables-restore < /root/my_iptables_config | |
3. Create a directory in your web application, I usually name mine /_es and add an .htaccess file. |
To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.
/** | |
* called when an item in the ListView is clicked; we will get the section | |
* index, and addition event information | |
* | |
* @param {Object} _event | |
*/ | |
function loadMoreBtnClicked(_event) { | |
alert('not implemented yet'); | |
} |
# added this to | |
sub vcl_recv { | |
if (req.http.host == "yourdomain.com") { | |
set req.http.Location = "http://www.yourdomain.com" + req.url; | |
error 750 "Permanently moved"; | |
} | |
} |
server { | |
listen 80; | |
listen [::]:80; | |
server_name domain.com; | |
autoindex off; | |
index index.php index.html; | |
root /srv/www/domain.com/public; |