Skip to content

Instantly share code, notes, and snippets.

@etrikp
etrikp / vagrant_file.rb
Created February 15, 2011 18:38
Test vagrant file
Vagrant::Config.run do |config|
config.vm.box = "lucid64_vb4"
config.vm.box_url = "http://basebox-server/lucid64_vb4.box"
config.vm.provision :chef_solo do |chef|
chef.cookbooks_path = "cookbooks"
chef.add_recipe("apt")
end
end
# -*- coding: utf-8 -*-
"""
flask.logging
~~~~~~~~~~~~~
Implements the logging support for Flask.
:copyright: (c) 2010 by Armin Ronacher.
:license: BSD, see LICENSE for more details.
"""
Rendering pull_requests/show
User Load (1.0ms) SELECT * FROM `users` WHERE (`users`.`id` = 6)
Repository Load (1.0ms) SELECT * FROM `repositories` WHERE (`repositories`.`source_id` = 4 AND `repositories`.`owner_id` = 2) LIMIT 1
Repository Exists (0.0ms) SELECT `repositories`.id FROM `repositories` INNER JOIN `watched_repositories` ON `repositories`.id = `watched_repositories`.repository_id WHERE (`repositories`.`id` = 4) AND (`watched_repositories`.user_id = 2 ) LIMIT 1
SQL (1.0ms) SELECT count(DISTINCT `users`.id) AS count_users_id FROM `users` INNER JOIN team_members ON users.id = team_members.organization_id WHERE ((`team_members`.user_id = 2)) AND ( (`users`.`type` = 'Organization' ) )
Organization Load (1.0ms) SELECT DISTINCT `users`.* FROM `users` INNER JOIN team_members ON users.id = team_members.organization_id WHERE ((`team_members`.user_id = 2)) AND ( (`users`.`type` = 'Organization' ) )
Repository Load (1.0ms) SELECT * FROM `repositories` WHERE (`repositories`.`source_id`
### Managed by Puppet ###
vrrp_script chk_haproxy {
script "/usr/bin/pgrep -u haproxy -f haproxy"
interval 1
weight 2
}
vrrp_script chk_sshd {
script "/usr/bin/killall -0 sshd"
interval 1
weight 2
# Attach Disk to the newly created controller
openstack.vm.customize ["storageattach", :id,
"--storagectl", "LsiLogic",
"--port", "0",
"--device", "0",
"--type", "hdd",
"--medium", "#{ENV['HOME']}/VirtualBox VMs/#{:id}/swift-disk1.vmdk"]
.
|-- environments
| `-- example_env
|-- hieradata
| |-- env
| |-- hiera-local
| `-- profile
|-- manifests
|-- modules
| |-- apt
#!/bin/bash
rm -rf modules/profile/
mkdir -p modules/profile/{manifests,files,templates}
if [ -d 'profiles' ]; then
for prof in `ls profiles`
do
if [ -d "profiles/$prof/manifests" ]; then
cp -R profiles/$prof/manifests/*.pp modules/profile/manifests/
if [ -d "profiles/$prof/files" ]; then
#!/bin/bash
#
# This script is meant to be put in the post creation phase of bringing up an instances
# It properly configures the seocond nic so the outside world is reachable.
cat << EOF > /etc/network/interfaces.d/eth1.cfg
# The primary network interface
auto eth1
iface eth1 inet dhcp
# Creates a new VM and attaches to a network and passes metadata to the instance
# Needs a recent version of eventlet per https://bugs.launchpad.net/nova/+bug/1266974
---
- name: create nimbus instance
hosts: localhost
connection: local
gather_facts: False
tasks:
- name: launch openldap instance
Routing tables
Internet:
Destination Gateway Flags Refs Use Netif Expire
default utun0 UCS 26 0 utun0
default 10.0.1.1 UGScI 0 0 en1
10.0.1/24 link#5 UCS 7 0 en1
10.0.1.1 20:c9:d0:13:c9:b3 UHLWIir 2 4672 en1 985
10.0.1.2 9c:20:7b:df:8a:11 UHLWI 0 0 en1 923
10.0.1.3 b4:7:f9:fb:1c:24 UHLWI 0 1093 en1 1200