From 2569ac0f345f48a6719ffc93d46e75303540e7ce Mon Sep 17 00:00:00 2001 From: inspurericzhang Date: Tue, 19 Nov 2019 15:24:25 +0800 Subject: [PATCH] Updates for rocky - Replace git.openstack.org with opendev.org - Update some documentation - Move README.md to README.rst for better rendering - Drop obsolete bootstrap.sh script Change-Id: If732a5e840a7080691097e429e692a18f5286db6 --- README.md => README.rst | 39 +++++++++++------------ Rakefile | 2 +- bootstrap.sh | 69 ----------------------------------------- metadata.rb | 7 ++--- 4 files changed, 24 insertions(+), 93 deletions(-) rename README.md => README.rst (89%) delete mode 100755 bootstrap.sh diff --git a/README.md b/README.rst similarity index 89% rename from README.md rename to README.rst index 3fc33514..9aeec41e 100644 --- a/README.md +++ b/README.rst @@ -1,12 +1,10 @@ -Team and repository tags -======================== +OpenStack Chef Cookbook - common +================================ [![Team and repository tags](http://governance.openstack.org/badges/cookbook-openstack-common.svg)](http://governance.openstack.org/reference/tags/index.html) -![Chef OpenStack Logo](https://www.openstack.org/themes/openstack/images/project-mascots/Chef%20OpenStack/OpenStack_Project_Chef_horizontal.png) - Description =========== @@ -14,15 +12,17 @@ This cookbook provides common setup recipes, helper methods and attributes that describe an OpenStack deployment as part of the OpenStack reference deployment Chef for OpenStack. -Please relate to the official OpenStack Configuration Reference for a more detailed documentation on operating and administration of an OpenStack cluster: +Please relate to the official OpenStack Configuration and Installation Guides for +a more detailed documentation on operating and administration of an OpenStack cluster: -http://docs.openstack.org/mitaka/config-reference/index.html +https://docs.openstack.org/latest/configuration/ +https://docs.openstack.org/latest/install/ Requirements ============ -- Chef 12 or higher -- chefdk 0.15.15 for testing (also includes berkshelf for cookbook dependency +- Chef 14 or higher +- chefdk 3.2.30 for testing (also includes berkshelf for cookbook dependency resolution) Platform @@ -37,13 +37,12 @@ Cookbooks The following cookbooks are dependencies: -- 'apt', '~> 2.8' -- 'database', '~> 4.0.2' -- 'mariadb', '~> 0.3.1' -- 'mysql', '~> 6.0.13' -- 'yum', '~> 3.5.4' -- 'yum-epel', '~> 0.6.0' -- 'galera', '~> 0.4.1' +- 'etcd', '~> 5.5' +- 'mariadb', '~> 1.5' +- 'memcached', '~> 4.1' +- 'mysql', '~> 8.2' +- 'selinux' +- 'yum-epel' Attributes ========== @@ -60,7 +59,7 @@ OpenStack service configuration files. The base template is the 'openstack-service.conf.erb' included in the templates of this cookbook. In each of the service cookbook (e.g. openstack-network, openstack-identity or openstack-compute), the service configuration file (e.g neutron.conf, -keystone.conf or nova.conf) gets generated directly from attributes set inside of +keystone.conf or nova.conf) gets generated directly from attributes set inside the cookbook. To merge all the configuration options (including the secrets) properly, before handing them over as '@service_config' to the mentioned template above, we use the methods defined in 'libraries/config_helpers'. @@ -71,7 +70,7 @@ openstack-network or attributes/keystone_conf.rb in openstack-identity). The basic structure of all these attributes always follows this model: ``` -# usual config option that should evventually be saved to the node object +# usual config option that should eventually be saved to the node object default['openstack'][service]['conf'][section][key][value] # configuration options like passwords that should not be saved in the node # object @@ -107,7 +106,7 @@ Documentation for Attributes for selecting databag format can be found in the attributes section of this cookbook. Documentation for format of these Databags can be found in the [Openstack Chef -Repo](https://github.com/openstack/openstack-chef#databags) repository. +Repo](https://opendev.org/openstack/openstack-chef#data-bags) repository. Resources ========= @@ -129,7 +128,7 @@ openstack_common_database 'compute' do end ``` -An example of the usage can be seen here https://github.com/stackforge/cookbook-openstack-ops-database/blob/master/recipes/openstack-db.rb. +An example of the usage can be seen here https://opendev.org/openstack/cookbook-openstack-ops-database/src/branch/master/recipes/openstack-db.rb . Libraries ========= @@ -260,6 +259,7 @@ License and Author | **Author** | Mark Vanderwiel () | | **Author** | Jan Klare () | | **Author** | Christoph Albers () | +| **Author** | Jens Harbott () | | | | | **Copyright** | Copyright (c) 2012-2013, AT&T Services, Inc. | | **Copyright** | Copyright (c) 2013, Opscode, Inc. | @@ -267,6 +267,7 @@ License and Author | **Copyright** | Copyright (c) 2013-2014, SUSE Linux GmbH | | **Copyright** | Copyright (c) 2013-2015, IBM, Corp. | | **Copyright** | Copyright (c) 2013-2014, Rackspace US, Inc. | +| **Copyright** | Copyright (c) 2016-2019, x-ion GmbH | Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/Rakefile b/Rakefile index a9c54b10..9076764f 100644 --- a/Rakefile +++ b/Rakefile @@ -47,7 +47,7 @@ task :common_integration do sh %(sudo ln -s #{patch_dir} ../#{patch_dir_berks}) unless Dir.exist?('../openstack-chef') - sh %(git clone --depth 1 git://github.com/openstack/openstack-chef.git ../openstack-chef) + sh %(git clone --depth 1 https://opendev.org/openstack/openstack-chef ../openstack-chef) end Dir.chdir('../openstack-chef') do diff --git a/bootstrap.sh b/bootstrap.sh deleted file mode 100755 index 1f562e70..00000000 --- a/bootstrap.sh +++ /dev/null @@ -1,69 +0,0 @@ -#!/bin/bash -x - -if [ $(id -u) != 0 ]; then - # preserve environment to keep ZUUL_* params - export SUDO='sudo -E' -fi - -# if we're in an integration gate, we're using OpenStack mirrors -if [ -f /etc/nodepool/provider ]; then - source /etc/nodepool/provider - NODEPOOL_MIRROR_HOST=${NODEPOOL_MIRROR_HOST:-mirror.$NODEPOOL_REGION.$NODEPOOL_CLOUD.openstack.org} - NODEPOOL_MIRROR_HOST=$(echo $NODEPOOL_MIRROR_HOST|tr '[:upper:]' '[:lower:]') - CENTOS_MIRROR_HOST=${NODEPOOL_MIRROR_HOST} - UCA_MIRROR_HOST="${NODEPOOL_MIRROR_HOST}/ubuntu-cloud-archive" - CEPH_MIRROR_HOST="${NODEPOOL_MIRROR_HOST}/ceph-deb-jewel" - NODEPOOL_RDO_PROXY=${NODEPOOL_RDO_PROXY} - NODEPOOL_RUBYGEMS_PROXY=${NODEPOOL_RUBYGEMS_PROXY} -else - CENTOS_MIRROR_HOST='mirror.centos.org' - UCA_MIRROR_HOST='ubuntu-cloud.archive.canonical.com/ubuntu' - CEPH_MIRROR_HOST='download.ceph.com/debian-jewel' -fi - -# The following will handle cross cookbook patch dependencies via the Depends-On in commit message - -# ZUUL_CHANGES has a ^ separated list of patches, the last being the current patch. -# The Depends_On will add patches to the front of this list. -echo $ZUUL_CHANGES -# Convert string list to array -cookbooks=(${ZUUL_CHANGES//^/ }) -# Remove the last one as it's the current cookbook -# TODO(MRV) At some point we could consider removing the gerrit-git-prep step from the rake job -# and also doing that patch clone with zuul-cloner. After gerrit-git-prep is removed, need to -# remove this unset line and adjust the clone map to have the base patch put into the current dir. -unset cookbooks[${#cookbooks[@]}-1] - -# Create clone map -cat > clonemap.yaml < 8.2' depends 'selinux' depends 'yum-epel' -issues_url 'https://launchpad.net/openstack-chef' if respond_to?(:issues_url) -source_url 'https://github.com/openstack/cookbook-openstack-common' if respond_to?(:source_url) -chef_version '>= 12.5' if respond_to?(:chef_version) +issues_url 'https://launchpad.net/openstack-chef' +source_url 'https://opendev.org/openstack/cookbook-openstack-common' +chef_version '>= 14.0'