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
--- | |
- job: | |
name: openstack-ansible-functional | |
parent: base | |
description: | | |
Run functional tests for an OpenStack-Ansible project. | |
Uses tox with the ``functional`` environment by default, | |
but the environment name can be changed through the use | |
of the ``tox_env`` variable. | |
required-projects: |
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
# The py_pkgs lookup will ignore all _git_ variables unless the | |
# _git_repo variable is present. As we're not wanting to use a | |
# fork in this case we just have the default value here. | |
magnum_git_repo: https://git.openstack.org/openstack/magnum | |
# Now we set the SHA/branch we want to build magnum from. | |
magnum_git_install_branch: "stable/pike" | |
# The key change is to allow the build to happen with the | |
# upstream indexes enabled (which is disabled by default to |
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
--- | |
# Copyright 2017, Ericsson AB | |
# | |
# 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 | |
# |
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
root@foo:~# rm -rf test; mkdir test; touch test/test{1,2,3}; chown ubuntu test/test1; chown aptly test/test2; ls -al test/ | |
total 8 | |
drwxr-xr-x 2 root root 4096 Nov 30 10:47 . | |
drwx------ 11 root root 4096 Nov 30 10:47 .. | |
-rw-r--r-- 1 ubuntu root 0 Nov 30 10:47 test1 | |
-rw-r--r-- 1 aptly root 0 Nov 30 10:47 test2 | |
-rw-r--r-- 1 root root 0 Nov 30 10:47 test3 | |
root@foo:~# rsync -avz --chown 'nginx:www-data' -e "ssh -i ~/.ssh/my.key" --verbose test root@bar:/tmp/ | |
opening connection using: ssh -i "~/.ssh/my.key" -l root bar rsync --server -vvlogDtprze.iLsfx "--usermap=*:nginx" "--groupmap=*:www-data" . /tmp/ (13 args) |
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
clouds: | |
_test_cloud_: | |
auth: | |
auth_url: https://identity.example.com | |
password: password | |
project_name: admin | |
username: admin | |
user_domain_name: default | |
project_domain_name: default | |
region_name: RegionOne |
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
--- | |
- name: Test conditional include (static) | |
hosts: localhost | |
connection: local | |
gather_facts: false | |
tasks: | |
- include: 01-included-tasks.yml | |
when: include_me | bool | |
- name: Test conditional include (dynamic) |
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
# prep host | |
apt update | |
apt purge nano | |
apt install git vim tmux fail2ban | |
# prep ssh key | |
key_path="${HOME}/.ssh" | |
key_file="${key_path}/id_rsa" | |
mkdir -p ${key_path} | |
chmod 700 ${key_path} |
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
# Physical interface, could be bond. This only needs to be set once | |
auto eth0 | |
iface eth0 inet manual | |
bond-master bond0 | |
bond-primary eth0 | |
auto eth1 | |
iface eth1 inet manual |
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
update_gh_status(){ | |
sha="$1" | |
state="$2" | |
description="$3" | |
context="$4" | |
owner="${5:-rcbops}" | |
repo="${6:-rpc-openstack}" | |
oauth_token="${7:-YOUR_PAT}" | |
if [[ ${#@} < 4 ]]; then |
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
# Setup | |
apt-get update && \ | |
apt-get purge -y nano && \ | |
apt-get install -y git vim tmux fail2ban | |
cd /opt | |
git clone https://github.com/openstack/openstack-ansible.git | |
cd openstack-ansible | |
export ANSIBLE_ROLE_FETCH_MODE="git-clone" |