Initial commit
This commit is contained in:
parent
49efd0642a
commit
651999d4b4
|
@ -1,89 +1,8 @@
|
||||||
# Byte-compiled / optimized / DLL files
|
.idea
|
||||||
__pycache__/
|
.tox
|
||||||
*.py[cod]
|
.build
|
||||||
*$py.class
|
*.pyc
|
||||||
|
*.deb
|
||||||
# C extensions
|
*.rpm
|
||||||
*.so
|
deployment_scripts/puppet/modules/congress
|
||||||
|
tmp
|
||||||
# Distribution / packaging
|
|
||||||
.Python
|
|
||||||
env/
|
|
||||||
build/
|
|
||||||
develop-eggs/
|
|
||||||
dist/
|
|
||||||
downloads/
|
|
||||||
eggs/
|
|
||||||
.eggs/
|
|
||||||
lib/
|
|
||||||
lib64/
|
|
||||||
parts/
|
|
||||||
sdist/
|
|
||||||
var/
|
|
||||||
*.egg-info/
|
|
||||||
.installed.cfg
|
|
||||||
*.egg
|
|
||||||
|
|
||||||
# PyInstaller
|
|
||||||
# Usually these files are written by a python script from a template
|
|
||||||
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
||||||
*.manifest
|
|
||||||
*.spec
|
|
||||||
|
|
||||||
# Installer logs
|
|
||||||
pip-log.txt
|
|
||||||
pip-delete-this-directory.txt
|
|
||||||
|
|
||||||
# Unit test / coverage reports
|
|
||||||
htmlcov/
|
|
||||||
.tox/
|
|
||||||
.coverage
|
|
||||||
.coverage.*
|
|
||||||
.cache
|
|
||||||
nosetests.xml
|
|
||||||
coverage.xml
|
|
||||||
*,cover
|
|
||||||
.hypothesis/
|
|
||||||
|
|
||||||
# Translations
|
|
||||||
*.mo
|
|
||||||
*.pot
|
|
||||||
|
|
||||||
# Django stuff:
|
|
||||||
*.log
|
|
||||||
local_settings.py
|
|
||||||
|
|
||||||
# Flask stuff:
|
|
||||||
instance/
|
|
||||||
.webassets-cache
|
|
||||||
|
|
||||||
# Scrapy stuff:
|
|
||||||
.scrapy
|
|
||||||
|
|
||||||
# Sphinx documentation
|
|
||||||
docs/_build/
|
|
||||||
|
|
||||||
# PyBuilder
|
|
||||||
target/
|
|
||||||
|
|
||||||
# IPython Notebook
|
|
||||||
.ipynb_checkpoints
|
|
||||||
|
|
||||||
# pyenv
|
|
||||||
.python-version
|
|
||||||
|
|
||||||
# celery beat schedule file
|
|
||||||
celerybeat-schedule
|
|
||||||
|
|
||||||
# dotenv
|
|
||||||
.env
|
|
||||||
|
|
||||||
# virtualenv
|
|
||||||
venv/
|
|
||||||
ENV/
|
|
||||||
|
|
||||||
# Spyder project settings
|
|
||||||
.spyderproject
|
|
||||||
|
|
||||||
# Rope project settings
|
|
||||||
.ropeproject
|
|
|
@ -1 +1,4 @@
|
||||||
# fuel-plugin-congress
|
The Congress plugin for Fuel
|
||||||
|
============================
|
||||||
|
|
||||||
|
The Congress plugin for Fuel is a plugin to install Congress.
|
|
@ -0,0 +1,5 @@
|
||||||
|
# This file contains additional bond attributes provided by plugin.
|
||||||
|
# Please, take a look at following link for the details:
|
||||||
|
# - https://blueprints.launchpad.net/fuel/+spec/nics-and-nodes-attributes-via-plugin
|
||||||
|
# - https://specs.openstack.org/openstack/fuel-specs/specs/10.0/nics-and-nodes-attributes-via-plugin.html
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
# This file contains wizard components descriptions that are pretty similar to
|
||||||
|
# the `environment_config.yaml`.
|
||||||
|
# Please, take a look at following link for the details:
|
||||||
|
# - https://blueprints.launchpad.net/fuel/+spec/component-registry
|
||||||
|
# - https://specs.openstack.org/openstack/fuel-specs/specs/8.0/component-registry.html
|
||||||
|
|
||||||
|
- name: additional_service:congress
|
||||||
|
compatible: []
|
||||||
|
requires: []
|
||||||
|
incompatible: []
|
||||||
|
label: "Install Congress"
|
||||||
|
description: "Component description (optional)"
|
|
@ -0,0 +1,3 @@
|
||||||
|
notice('MODULAR: congress.pp')
|
||||||
|
|
||||||
|
# TODO implement
|
|
@ -0,0 +1,43 @@
|
||||||
|
# These tasks will be merged into deployment graph. Here you
|
||||||
|
# can specify new tasks for any roles, even built-in ones.
|
||||||
|
|
||||||
|
- id: congress
|
||||||
|
type: group
|
||||||
|
role: [congress]
|
||||||
|
parameters:
|
||||||
|
strategy:
|
||||||
|
type: parallel
|
||||||
|
|
||||||
|
- id: congress-install
|
||||||
|
type: puppet
|
||||||
|
version: 2.1.0
|
||||||
|
groups: [congress]
|
||||||
|
cross-depends:
|
||||||
|
- name: congress-db
|
||||||
|
- name: congress-keystone
|
||||||
|
parameters:
|
||||||
|
puppet_manifest: puppet/manifests/congress.pp
|
||||||
|
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||||
|
timeout: 3600
|
||||||
|
|
||||||
|
- id: congress-keystone
|
||||||
|
type: puppet
|
||||||
|
version: 2.1.0
|
||||||
|
groups: [primary-controller]
|
||||||
|
cross-depends:
|
||||||
|
- name: /(primary-)?keystone/
|
||||||
|
parameters:
|
||||||
|
puppet_manifest: puppet/manifests/congress-keystone.pp
|
||||||
|
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||||
|
timeout: 1800
|
||||||
|
|
||||||
|
- id: congress-db
|
||||||
|
type: puppet
|
||||||
|
version: 2.1.0
|
||||||
|
groups: [primary-controller]
|
||||||
|
cross-depends:
|
||||||
|
- name: /(primary-)?database/
|
||||||
|
parameters:
|
||||||
|
puppet_manifest: puppet/manifests/congess-db.pp
|
||||||
|
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||||
|
timeout: 1800
|
|
@ -0,0 +1,18 @@
|
||||||
|
attributes:
|
||||||
|
metadata:
|
||||||
|
# Settings group can be one of "general", "security", "compute", "network",
|
||||||
|
# "storage", "logging", "openstack_services" and "other".
|
||||||
|
group: 'openstack_services'
|
||||||
|
db_password:
|
||||||
|
generator: 'password'
|
||||||
|
user_password:
|
||||||
|
generator: 'password'
|
||||||
|
user: 'congress'
|
||||||
|
port: 1789
|
||||||
|
service: 'congress-server'
|
||||||
|
debug:
|
||||||
|
value: false
|
||||||
|
label: 'Debug logging'
|
||||||
|
description: 'Debug logging mode provides more information, but requires more disk space.'
|
||||||
|
weight: 25
|
||||||
|
type: "checkbox"
|
|
@ -0,0 +1,38 @@
|
||||||
|
# Plugin name
|
||||||
|
name: fuel-plugin-congress
|
||||||
|
# Human-readable name for your plugin
|
||||||
|
title: Fuel Congress plugin
|
||||||
|
# Plugin version
|
||||||
|
version: '1.0.0'
|
||||||
|
# Description
|
||||||
|
description: Install Congress
|
||||||
|
# Required fuel version
|
||||||
|
fuel_version: ['9.0', '10.0']
|
||||||
|
# Specify license of your plugin
|
||||||
|
licenses: ['Apache License Version 2.0']
|
||||||
|
# Specify author or company name
|
||||||
|
authors: ['Fedor Zhadaev', 'Mirantis']
|
||||||
|
# A link to the plugin's page
|
||||||
|
homepage: 'https://github.com/openstack/fuel-plugin-congress'
|
||||||
|
# Specify a group which your plugin implements, possible options:
|
||||||
|
# network, storage, storage::cinder, storage::glance, hypervisor
|
||||||
|
groups: []
|
||||||
|
# Change `false` to `true` if the plugin can be installed in the environment
|
||||||
|
# after the deployment.
|
||||||
|
is_hotpluggable: false
|
||||||
|
|
||||||
|
# The plugin is compatible with releases in the list
|
||||||
|
releases:
|
||||||
|
- os: ubuntu
|
||||||
|
version: mitaka-9.0
|
||||||
|
mode: ['ha']
|
||||||
|
deployment_scripts_path: deployment_scripts/
|
||||||
|
repository_path: repositories/ubuntu
|
||||||
|
- os: ubuntu
|
||||||
|
version: newton-10.0
|
||||||
|
mode: ['ha']
|
||||||
|
deployment_scripts_path: deployment_scripts/
|
||||||
|
repository_path: repositories/ubuntu
|
||||||
|
|
||||||
|
# Version of plugin package
|
||||||
|
package_version: '5.0.0'
|
|
@ -0,0 +1 @@
|
||||||
|
[]
|
|
@ -0,0 +1,4 @@
|
||||||
|
# This file contains additional nic attributes provided by plugin.
|
||||||
|
# Please, take a look at following link for the details:
|
||||||
|
# - https://blueprints.launchpad.net/fuel/+spec/nics-and-nodes-attributes-via-plugin
|
||||||
|
# - https://specs.openstack.org/openstack/fuel-specs/specs/10.0/nics-and-nodes-attributes-via-plugin.html
|
|
@ -0,0 +1,4 @@
|
||||||
|
# This file contains additional node's attributes provided by plugin.
|
||||||
|
# Please, take a look at following link for the details:
|
||||||
|
# - https://blueprints.launchpad.net/fuel/+spec/nics-and-nodes-attributes-via-plugin
|
||||||
|
# - https://specs.openstack.org/openstack/fuel-specs/specs/10.0/nics-and-nodes-attributes-via-plugin.html
|
|
@ -0,0 +1,6 @@
|
||||||
|
congress:
|
||||||
|
name: "Congress"
|
||||||
|
description: "Install Congress"
|
||||||
|
has_primary: false
|
||||||
|
public_ip_required: false
|
||||||
|
weight: 150
|
|
@ -0,0 +1,70 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Add here any the actions which are required before plugin build
|
||||||
|
# like packages building, packages downloading from mirrors and so on.
|
||||||
|
# The script should return 0 if there were no errors.
|
||||||
|
|
||||||
|
set -eux
|
||||||
|
|
||||||
|
ROOT="$(dirname "$(readlink -f "$0")")"
|
||||||
|
MODULES_DIR="${ROOT}/deployment_scripts/puppet/modules"
|
||||||
|
TMP_DIR="${ROOT}/tmp"
|
||||||
|
UBUNTU_REPO_DIR="${ROOT}/repositories/ubuntu"
|
||||||
|
|
||||||
|
CONGRESS_PUPPET_REPO=${CONGRESS_PUPPET_REPO:-'https://github.com/openstack/puppet-congress.git'}
|
||||||
|
CONGRESS_PUPPET_BRANCH=${CONGRESS_PUPPET_BRANCH:-'master'}
|
||||||
|
CONGRESS_PUPPET_DST_DIR="${MODULES_DIR}/congress"
|
||||||
|
|
||||||
|
CONGRESS_REPO=${CONGRESS_REPO:-'https://github.com/openstack/congress.git'}
|
||||||
|
CONGRESS_BRANCH=${CONGRESS_BRANCH:-'stable/newton'}
|
||||||
|
CONGRESS_DST_DIR="${TMP_DIR}/congress"
|
||||||
|
|
||||||
|
CONGRESS_CLI_REPO=${CONGRESS_CLI_REPO:-'https://github.com/openstack/python-congressclient.git'}
|
||||||
|
CONGRESS_CLI_BRANCH=${CONGRESS_CLI_BRANCH:-'stable/newton'}
|
||||||
|
CONGRESS_CLI_DST_DIR="${TMP_DIR}/python-congressclient"
|
||||||
|
|
||||||
|
function git_download {
|
||||||
|
local git_repo=$1
|
||||||
|
local git_branch=$2
|
||||||
|
local dst_dir=$3
|
||||||
|
|
||||||
|
rm -rvf "$dst_dir"
|
||||||
|
git clone "${git_repo}" --single-branch -b "${git_branch}" "${dst_dir}"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Remove temp directory
|
||||||
|
function clean {
|
||||||
|
rm -rf "${TMP_DIR}"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function check_fpm {
|
||||||
|
command -v fpm > /dev/null 2>&1 || { echo >&2 "ERROR: fpm ruby gem is not installed. Aborting."; exit 1; }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function build_deb {
|
||||||
|
pushd "${UBUNTU_REPO_DIR}"
|
||||||
|
|
||||||
|
fpm --force -s python -t deb --python-install-bin /usr/bin --python-install-lib /usr/lib/python2.7/dist-packages "${CONGRESS_DST_DIR}/setup.py"
|
||||||
|
fpm --force -s python -t deb --python-install-lib /usr/lib/python2.7/dist-packages "${CONGRESS_CLI_DST_DIR}/setup.py"
|
||||||
|
|
||||||
|
popd
|
||||||
|
|
||||||
|
}
|
||||||
|
check_fpm
|
||||||
|
|
||||||
|
clean
|
||||||
|
|
||||||
|
git_download "${CONGRESS_PUPPET_REPO}" "${CONGRESS_PUPPET_BRANCH}" "${CONGRESS_PUPPET_DST_DIR}"
|
||||||
|
|
||||||
|
git_download "${CONGRESS_REPO}" "${CONGRESS_BRANCH}" "${CONGRESS_DST_DIR}"
|
||||||
|
|
||||||
|
git_download "${CONGRESS_CLI_REPO}" "${CONGRESS_CLI_BRANCH}" "${CONGRESS_CLI_DST_DIR}"
|
||||||
|
|
||||||
|
build_deb
|
||||||
|
|
||||||
|
clean
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,29 @@
|
||||||
|
# WARNING: `tasks.yaml` will be deprecated in further releases.
|
||||||
|
# Please, use `deployment_tasks.yaml` to describe tasks instead.
|
||||||
|
|
||||||
|
# This file is left only as an example of the old tasks format what you could
|
||||||
|
# meet during plugins development and support.
|
||||||
|
|
||||||
|
## This tasks will be applied on controller nodes,
|
||||||
|
## here you can also specify several roles, for example
|
||||||
|
## ['cinder', 'compute'] will be applied only on
|
||||||
|
## cinder and compute nodes
|
||||||
|
#- role: ['controller']
|
||||||
|
# stage: post_deployment
|
||||||
|
# type: shell
|
||||||
|
# parameters:
|
||||||
|
# cmd: bash deploy.sh
|
||||||
|
# timeout: 42
|
||||||
|
## Task is applied for all roles
|
||||||
|
#- role: '*'
|
||||||
|
# stage: pre_deployment
|
||||||
|
# type: shell
|
||||||
|
# parameters:
|
||||||
|
# cmd: echo all > /tmp/plugin.all
|
||||||
|
# timeout: 42
|
||||||
|
## "reboot" task reboots the nodes and waits until they get back online
|
||||||
|
## - role: '*'
|
||||||
|
## stage: pre_deployment
|
||||||
|
## type: reboot
|
||||||
|
## parameters:
|
||||||
|
## timeout: 600
|
|
@ -0,0 +1,4 @@
|
||||||
|
volumes_roles_mapping:
|
||||||
|
congress:
|
||||||
|
- {allocate_size: "min", id: "os"}
|
||||||
|
volumes: []
|
Loading…
Reference in New Issue