This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define monit_file($ensure = 'absent') { | |
| include monit | |
| case $ensure { | |
| 'present': { | |
| file { | |
| "/etc/monit.d/${name}.run": | |
| owner => "root", group => "root", mode => "0644", | |
| replace => true, | |
| source => "puppet:///monit/${name}.run", | |
| notify => Service["monit"]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Merb.logger.info("Compiling routes...") | |
| Merb::Router.prepare do |r| | |
| # This deferred route allows permalinks to be handled, without a separate rack handler | |
| match("/:permalink").defer_to do |request, params| | |
| unless (article = Article.find_by_permalink(params[:permalink)).nil? | |
| {:controller => "articles", :action => "show", :id => article.id} | |
| end | |
| end | |
| # Admin namespace |
NewerOlder