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
| #!/usr/bin/env python | |
| """This is a demonstration of sharing file descriptors across processes. | |
| It uses Tornado (need a recent post-2.0 version from github) and the | |
| multiprocessing module (from python 2.6+). To run it, start one copy | |
| of fdserver.py and one or more copies of testserver.py (in different | |
| terminals, or backgrounded, etc). Fetch http://localhost:8000 and | |
| you'll see the requests getting answered by different processes (it's | |
| normal for several requests to go to the same process under light | |
| load, but under heavier load it tends to even out). |
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
| include_recipe "postgresql::server90" | |
| # inspiration from | |
| # https://gist.github.com/637579 | |
| execute "create-root-user" do | |
| code = <<-EOH | |
| psql -U postgres -c "select * from pg_user where usename='root'" | grep -c root | |
| EOH | |
| command "createuser -U postgres -s root" |
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
| $ java -jar jenkins-cli.jar -s http://localhost:9000 install-plugin findbugs | |
| findbugs is neither a valid file, URL, nor a plugin artifact name in the update center | |
| No update center data is retrieved yet from: http://updates.jenkins-ci.org/update-center.json | |
| findbugs looks like a short plugin name. Did you mean 'null'? | |
| # Specifying a full URL works! | |
| $ java -jar jenkins-cli.jar -s http://localhost:9020 install-plugin http://updates.jenkins-ci.org/download/plugins/AdaptivePlugin/0.1/AdaptivePlugin.hpi | |
| # Get the update center ourself |
NewerOlder