From e2a6168655ac43d8fa70cfb21dc9c6713f09953c Mon Sep 17 00:00:00 2001 From: Bruce Ashfield Date: Thu, 31 Oct 2013 00:24:55 -0400 Subject: keystone: update to havana version Updating the keystone OpenStack component to the havana release version. As part of this switch, we also start building out of git versus the release tarballs. Signed-off-by: Bruce Ashfield --- .../python/python-keystone_2013.1.3.bb | 112 -------------------- .../recipes-devtools/python/python-keystone_git.bb | 114 +++++++++++++++++++++ .../python/python-keystoneclient_0.2.3.bb | 23 ----- .../python/python-keystoneclient_git.bb | 24 +++++ 4 files changed, 138 insertions(+), 135 deletions(-) delete mode 100644 meta-openstack/recipes-devtools/python/python-keystone_2013.1.3.bb create mode 100644 meta-openstack/recipes-devtools/python/python-keystone_git.bb delete mode 100644 meta-openstack/recipes-devtools/python/python-keystoneclient_0.2.3.bb create mode 100644 meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb (limited to 'meta-openstack') diff --git a/meta-openstack/recipes-devtools/python/python-keystone_2013.1.3.bb b/meta-openstack/recipes-devtools/python/python-keystone_2013.1.3.bb deleted file mode 100644 index 387fa68..0000000 --- a/meta-openstack/recipes-devtools/python/python-keystone_2013.1.3.bb +++ /dev/null @@ -1,112 +0,0 @@ -DESCRIPTION = "Authentication service for OpenStack" -HOMEPAGE = "http://www.openstack.org" -SECTION = "devel/python" -LICENSE = "Apache-2.0" -LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2" - -PR = "r0" -SRCNAME = "keystone" - -SRC_URI = "https://launchpad.net/keystone/grizzly/${PV}/+download/${SRCNAME}-${PV}.tar.gz \ - file://keystone.conf \ - file://identity.sh \ - file://keystone \ - file://openrc \ - " - -SRC_URI[md5sum] = "49bfcd088426960ef787d040ea8426af" -SRC_URI[sha256sum] = "e097170ebb1cf22de50f2d5ab2216a5116ffe0934720dbad8b02d61c370b8261" - -S = "${WORKDIR}/${SRCNAME}-${PV}" - -inherit setuptools update-rc.d identity hosts - -SERVICE_TOKEN = "password" - -do_install_append() { - - KEYSTONE_CONF_DIR=${D}${sysconfdir}/keystone - - install -d ${KEYSTONE_CONF_DIR} - - sed -e "s:%SERVICE_TOKEN%:${SERVICE_TOKEN}:g" -i ${WORKDIR}/keystone.conf - sed -e "s:%DB_USER%:${DB_USER}:g" -i ${WORKDIR}/keystone.conf - sed -e "s:%DB_PASSWORD%:${DB_PASSWORD}:g" -i ${WORKDIR}/keystone.conf - - sed -e "s:%CONTROLLER_IP%:${CONTROLLER_IP}:g" -i ${WORKDIR}/keystone.conf - sed -e "s:%CONTROLLER_IP%:${CONTROLLER_IP}:g" -i ${WORKDIR}/identity.sh - - install -d ${D}${localstatedir}/log/${SRCNAME} - - install -m 600 ${WORKDIR}/keystone.conf ${KEYSTONE_CONF_DIR}/ - install -m 600 ${WORKDIR}/identity.sh ${KEYSTONE_CONF_DIR}/ - install -m 600 ${WORKDIR}/openrc ${KEYSTONE_CONF_DIR}/ - install -m 600 ${S}/etc/logging.conf.sample ${KEYSTONE_CONF_DIR}/logging.conf - install -m 600 ${S}/etc/policy.json ${KEYSTONE_CONF_DIR}/policy.json - - if ${@base_contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then - install -d ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/keystone ${D}${sysconfdir}/init.d/keystone - fi -} - -pkg_postinst_${SRCNAME} () { - # python-keystone postinst start - if [ "x$D" != "x" ]; then - exit 1 - fi - - # This is to make sure postgres is configured and running - if ! pidof postmaster > /dev/null; then - /etc/init.d/postgresql-init - /etc/init.d/postgresql start - sleep 5 - fi - - sudo -u postgres createdb keystone - keystone-manage db_sync - keystone-manage pki_setup - - # Create users, services and endpoints - /etc/init.d/keystone start - sleep 2 - - ADMIN_PASSWORD=${ADMIN_PASSWORD} \ - SERVICE_PASSWORD=${SERVICE_PASSWORD} \ - SERVICE_TENANT_NAME=${SERVICE_TENANT_NAME} \ - bash /etc/keystone/identity.sh - - # end python-keystone postinst -} - -PACKAGES += " ${SRCNAME}" - -FILES_${PN} = "${libdir}/*" - -FILES_${SRCNAME} = "${bindir}/* \ - ${sysconfdir}/${SRCNAME}/* \ - ${sysconfdir}/init.d/* \ - ${localstatedir}/* \ - " - -RDEPENDS_${PN} += "python-pam \ - python-webob \ - python-eventlet \ - python-greenlet \ - python-pastedeploy \ - python-paste \ - python-routes \ - python-sqlalchemy \ - python-sqlalchemy-migrate \ - python-passlib \ - python-lxml \ - python-iso8601 \ - python-keystoneclient \ - python-oslo.config \ - " - -RDEPENDS_${SRCNAME} = "${PN} \ - postgresql postgresql-client python-psycopg2" - -INITSCRIPT_PACKAGES = "${SRCNAME}" -INITSCRIPT_NAME_${SRCNAME} = "keystone" diff --git a/meta-openstack/recipes-devtools/python/python-keystone_git.bb b/meta-openstack/recipes-devtools/python/python-keystone_git.bb new file mode 100644 index 0000000..882848a --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-keystone_git.bb @@ -0,0 +1,114 @@ +DESCRIPTION = "Authentication service for OpenStack" +HOMEPAGE = "http://www.openstack.org" +SECTION = "devel/python" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2" + +PR = "r0" +SRCNAME = "keystone" + +SRC_URI = "git://github.com/openstack/${SRCNAME}.git;branch=stable/havana \ + file://keystone.conf \ + file://identity.sh \ + file://keystone \ + file://openrc \ + " + +SRCREV="4221b6020e6b0b42325d8904d7b8a22577a6acc0" +PV="2013.2+git${SRCPV}" + +S = "${WORKDIR}/git" + +inherit setuptools update-rc.d identity hosts + +SERVICE_TOKEN = "password" + +do_install_append() { + + KEYSTONE_CONF_DIR=${D}${sysconfdir}/keystone + + install -d ${KEYSTONE_CONF_DIR} + + sed -e "s:%SERVICE_TOKEN%:${SERVICE_TOKEN}:g" -i ${WORKDIR}/keystone.conf + sed -e "s:%DB_USER%:${DB_USER}:g" -i ${WORKDIR}/keystone.conf + sed -e "s:%DB_PASSWORD%:${DB_PASSWORD}:g" -i ${WORKDIR}/keystone.conf + + sed -e "s:%CONTROLLER_IP%:${CONTROLLER_IP}:g" -i ${WORKDIR}/keystone.conf + sed -e "s:%CONTROLLER_IP%:${CONTROLLER_IP}:g" -i ${WORKDIR}/identity.sh + + install -d ${D}${localstatedir}/log/${SRCNAME} + + install -m 600 ${WORKDIR}/keystone.conf ${KEYSTONE_CONF_DIR}/ + install -m 600 ${WORKDIR}/identity.sh ${KEYSTONE_CONF_DIR}/ + install -m 600 ${WORKDIR}/openrc ${KEYSTONE_CONF_DIR}/ + install -m 600 ${S}/etc/logging.conf.sample ${KEYSTONE_CONF_DIR}/logging.conf + install -m 600 ${S}/etc/policy.json ${KEYSTONE_CONF_DIR}/policy.json + + if ${@base_contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then + install -d ${D}${sysconfdir}/init.d + install -m 0755 ${WORKDIR}/keystone ${D}${sysconfdir}/init.d/keystone + fi +} + +pkg_postinst_${SRCNAME} () { + # python-keystone postinst start + if [ "x$D" != "x" ]; then + exit 1 + fi + + # This is to make sure postgres is configured and running + if ! pidof postmaster > /dev/null; then + /etc/init.d/postgresql-init + /etc/init.d/postgresql start + sleep 5 + fi + + sudo -u postgres createdb keystone + keystone-manage db_sync + keystone-manage pki_setup --keystone-user=root --keystone-group=root + + # Create users, services and endpoints + /etc/init.d/keystone start + sleep 2 + + ADMIN_PASSWORD=${ADMIN_PASSWORD} \ + SERVICE_PASSWORD=${SERVICE_PASSWORD} \ + SERVICE_TENANT_NAME=${SERVICE_TENANT_NAME} \ + bash /etc/keystone/identity.sh + + # end python-keystone postinst +} + +PACKAGES += " ${SRCNAME}" + +FILES_${PN} = "${libdir}/*" + +FILES_${SRCNAME} = "${bindir}/* \ + ${sysconfdir}/${SRCNAME}/* \ + ${sysconfdir}/init.d/* \ + ${localstatedir}/* \ + " + +RDEPENDS_${PN} += "python-pam \ + python-webob \ + python-eventlet \ + python-greenlet \ + python-pastedeploy \ + python-paste \ + python-routes \ + python-sqlalchemy \ + python-sqlalchemy-migrate \ + python-passlib \ + python-lxml \ + python-iso8601 \ + python-keystoneclient \ + python-oslo.config \ + python-dogpile.core \ + python-dogpile.cache \ + " + +RDEPENDS_${SRCNAME} = "${PN} \ + postgresql postgresql-client python-psycopg2" + +INITSCRIPT_PACKAGES = "${SRCNAME}" +INITSCRIPT_NAME_${SRCNAME} = "keystone" diff --git a/meta-openstack/recipes-devtools/python/python-keystoneclient_0.2.3.bb b/meta-openstack/recipes-devtools/python/python-keystoneclient_0.2.3.bb deleted file mode 100644 index 18c0f64..0000000 --- a/meta-openstack/recipes-devtools/python/python-keystoneclient_0.2.3.bb +++ /dev/null @@ -1,23 +0,0 @@ -DESCRIPTION = "Client library for OpenStack Identity API" -HOMEPAGE = "https://github.com/openstack/python-keystoneclient" -SECTION = "devel/python" -LICENSE = "Apache-2.0" -LIC_FILES_CHKSUM = "file://LICENSE;md5=4a4d0e932ffae1c0131528d30d419c55" - -PR = "r0" - -SRC_URI = "http://pypi.python.org/packages/source/p/${PN}/${PN}-${PV}.tar.gz" - -SRC_URI[md5sum] = "ad6fcbdd0e4cb239d315155bdbe9337c" -SRC_URI[sha256sum] = "10b98946aaa98e97f032ca44848a5d84bc61d6f0b4186c635704087e72c08818" - -inherit setuptools - -FILES_${PN}-doc += "${datadir}/keystoneclient" - -RDEPENDS_${PN} += "python-iso8601 \ - python-prettytable \ - python-requests \ - python-simplejson \ - python-oslo.config \ - " diff --git a/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb b/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb new file mode 100644 index 0000000..827a551 --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb @@ -0,0 +1,24 @@ +DESCRIPTION = "Client library for OpenStack Identity API" +HOMEPAGE = "https://github.com/openstack/python-keystoneclient" +SECTION = "devel/python" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=4a4d0e932ffae1c0131528d30d419c55" + +PR = "r0" + +SRC_URI = "git://github.com/openstack/python-keystoneclient.git;branch=master" + +PV="git${SRCPV}" +SRCREV="0774d5aafade9e5a5de3830de461843c4a7d59a1" +S = "${WORKDIR}/git" + +inherit setuptools + +FILES_${PN}-doc += "${datadir}/keystoneclient" + +RDEPENDS_${PN} += "python-iso8601 \ + python-prettytable \ + python-requests \ + python-simplejson \ + python-oslo.config \ + " -- cgit v1.2.3-54-g00ecf