These are field notes gathered during installation of website search facility for the ElasticSearch website.
You may re-use it to put a similar system in place.
The following assumes:
| # -------------------------------------------- | |
| # General | |
| # -------------------------------------------- | |
| set :shared_children, %w(cache logs) # Shared directories, these directories contain generated content which should not be wiped out during deployments. | |
| set :application, "domain.com" # Application name | |
| set :deploy_to, "/var/www/#{application}/#{stage}" # Path where files are deployed to ... | |
| # -------------------------------------------- | |
| # Server | |
| # -------------------------------------------- |
| <?php | |
| /** | |
| * PluginRoute class. | |
| * | |
| * Route class for plugins that allows you to clean up urls for plugins | |
| * without tons of calls to Router::connect() to shorten controller names in urls. | |
| */ | |
| class PluginRoute extends CakeRoute | |
| { |
| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"> | |
| <html> | |
| <head> | |
| {{ html.charset() }} | |
| <title>{{ 'CakePHP: the rapid development php framework'|trans }}: {{ title_for_layout }}</title> | |
| {{ html.meta('icon') }} | |
| {{ html.css('cake.generic') }} | |
| {{ scripts_for_layout }} | |
| </head> | |
| <body> |
| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" | |
| "http://www.w3.org/TR/html4/strict.dtd"> | |
| <html> | |
| <head> | |
| <!-- Licensed under Yahoo! BSD license http://gist.github.com/375593 --> | |
| </head> | |
| <body> | |
| <span id="login"></span> | |
| doctrine_user.config: | |
| db_driver: odm | |
| class: | |
| model: | |
| user: Bundle\ExerciseUserBundle\Document\User | |
| group: ~ | |
| permission: ~ | |
| form: | |
| user: ~ | |
| group: ~ |
| $ git clone github:lenary/guides.git | |
| Cloning into guides... | |
| remote: Counting objects: 255, done. | |
| remote: Compressing objects: 100% (216/216), done. | |
| remote: Total 255 (delta 111), reused 163 (delta 35) | |
| Receiving objects: 100% (255/255), 1.49 MiB | 564 KiB/s, done. | |
| Resolving deltas: 100% (111/111), done. | |
| $ cd guides | |
| $ git remote -v |
| jQuery.fn.noisy = function(opacity) { | |
| if (typeof(opacity) === 'undefined') { | |
| opacity = 0.1; | |
| } | |
| var wrapper = jQuery(this).wrapInner('<div />').children(); | |
| var canvas = document.createElement("canvas"); | |
| canvas.width = 100; | |
| canvas.height = 100; | |
| var ctx = canvas.getContext("2d"); |
These are field notes gathered during installation of website search facility for the ElasticSearch website.
You may re-use it to put a similar system in place.
The following assumes:
| # Optimized for writes, sort on read | |
| # LVC | |
| redis.hset("bonds|1", "bid_price", 96.01) | |
| redis.hset("bonds|1", "ask_price", 97.53) | |
| redis.hset("bonds|2", "bid_price", 95.50) | |
| redis.hset("bonds|2", "ask_price", 98.25) | |
| redis.sadd("bond_ids", 1) | |
| redis.sadd("bond_ids", 2) |