Skip to content

Instantly share code, notes, and snippets.

David Moreau Simard dmsimard

View GitHub Profile
View packstack.sh
#!/bin/bash
# Workaround for known issues installing Packstack for OpenStack Mitaka RDO Test days
# https://etherpad.openstack.org/p/rdo-test-days-mitaka-m1
yum -y install yum-plugin-priorities
# Add Mitaka repositories
curl http://trunk.rdoproject.org/centos7/delorean-deps.repo |tee /etc/yum.repos.d/delorean-deps.repo
curl http://trunk.rdoproject.org/centos7/current/delorean.repo |tee /etc/yum.repos.d/delorean.repo
# Install packstack and dependencies
View role_tasks_main.yml
---
tasks:
- block:
- debug: msg='I execute normally'
- command: /bin/false
rescue:
- include: rescue.yml
@dmsimard
dmsimard / gist:7304179
Created Nov 4, 2013
Example init.pp puppet-ceph (stackforge)
View gist:7304179
class { 'ceph::repo':
release => "dumpling"
}
class { 'ceph::init': }
Class['ceph::repo'] -> Class['ceph::init']
@dmsimard
dmsimard / gist:7305126
Created Nov 4, 2013
ceph_init_systemspec
View gist:7305126
# Copyright (C) iWeb Technologies Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
View role_defaults_main
key: 6bf597e0-8a98-478b-9a88-e9e389fdfd38
View main
- name: Capture facts for output to file
setup:
register: ansible_facts
- name: Output facts to file
copy:
content: "{{ ansible_facts | to_nice_json }}"
dest: "./before.txt"
- set_fact:
View play
roles:
- { role: 'role', foo: 'bar' }
View test-puppet-with-delorean
#!/bin/bash
yum -y install python-setuptools redhat-lsb-core wget "@Development Tools" git yum-plugin-priorities libxml2-devel libxslt-devel ruby-devel rubygems
gem install bundler
export SCENARIO="scenario002"
export MANAGE_REPOS="false"
curl http://trunk.rdoproject.org/centos7/current/delorean.repo -o /etc/yum.repos.d/delorean.repo
curl http://trunk.rdoproject.org/centos7/delorean-deps.repo -o /etc/yum.repos.d/delorean-deps.repo
git clone https://github.com/openstack/puppet-openstack-integration.git
cd puppet-openstack-integration
./run_tests.sh
View packstack.sh
#!/bin/bash -ex
# Exit if we're not running on rhel-like
if [ -f /etc/os-release ]; then
source /etc/os-release
test "$ID" = "fedora" -o "$ID" = "centos"
else
exit 1
fi
if [ $(id -u) != 0 ]; then
You can’t perform that action at this time.