Implement Almanach Docker images
Almanach record the utilization of OpenStack resources for each tenant. Implements: blueprint containerized-almanach Change-Id: Iba2e16772864a6f0169ec43d7a87d741882cd51c
This commit is contained in:
parent
9674e2da1c
commit
b8f7693d41
|
@ -75,6 +75,7 @@ OpenStack services
|
||||||
|
|
||||||
Kolla provides images to deploy the following OpenStack projects:
|
Kolla provides images to deploy the following OpenStack projects:
|
||||||
|
|
||||||
|
- `Almanach <https://almanach.readthedocs.io/>`__
|
||||||
- `Aodh <https://docs.openstack.org/aodh/latest/>`__
|
- `Aodh <https://docs.openstack.org/aodh/latest/>`__
|
||||||
- `Barbican <https://docs.openstack.org/barbican/latest/>`__
|
- `Barbican <https://docs.openstack.org/barbican/latest/>`__
|
||||||
- `Bifrost <https://docs.openstack.org/bifrost/latest/>`__
|
- `Bifrost <https://docs.openstack.org/bifrost/latest/>`__
|
||||||
|
|
|
@ -0,0 +1,16 @@
|
||||||
|
FROM {{ namespace }}/{{ image_prefix }}almanach-base:{{ tag }}
|
||||||
|
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
|
||||||
|
|
||||||
|
{% block almanach_api_header %}{% endblock %}
|
||||||
|
|
||||||
|
{% if install_type == 'binary' %}
|
||||||
|
|
||||||
|
RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \
|
||||||
|
&& /bin/false
|
||||||
|
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% block almanach_api_footer %}{% endblock %}
|
||||||
|
{% block footer %}{% endblock %}
|
||||||
|
|
||||||
|
USER almanach
|
|
@ -0,0 +1,34 @@
|
||||||
|
FROM {{ namespace }}/{{ image_prefix }}openstack-base:{{ tag }}
|
||||||
|
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
|
||||||
|
|
||||||
|
{% block almanach_base_header %}{% endblock %}
|
||||||
|
|
||||||
|
{% import "macros.j2" as macros with context %}
|
||||||
|
|
||||||
|
{{ macros.configure_user(name='almanach') }}
|
||||||
|
|
||||||
|
{% if install_type == 'binary' %}
|
||||||
|
|
||||||
|
RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \
|
||||||
|
&& /bin/false
|
||||||
|
|
||||||
|
{% elif install_type == 'source' %}
|
||||||
|
|
||||||
|
ADD almanach-base-archive /almanach-base-source
|
||||||
|
|
||||||
|
{% set almanach_base_pip_packages = [
|
||||||
|
'/almanach'
|
||||||
|
] %}
|
||||||
|
|
||||||
|
RUN ln -s almanach-base-source/* almanach \
|
||||||
|
&& {{ macros.install_pip(almanach_base_pip_packages | customizable("pip_packages")) }} \
|
||||||
|
&& mkdir -p /etc/almanach \
|
||||||
|
&& chown -R almanach: /etc/almanach
|
||||||
|
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||||
|
|
||||||
|
RUN chmod 755 /usr/local/bin/kolla_extend_start
|
||||||
|
|
||||||
|
{% block almanach_base_footer %}{% endblock %}
|
|
@ -0,0 +1,8 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [[ ! -d "/var/log/kolla/almanach" ]]; then
|
||||||
|
mkdir -p /var/log/kolla/almanach
|
||||||
|
fi
|
||||||
|
if [[ $(stat -c %a /var/log/kolla/almanach) != "755" ]]; then
|
||||||
|
chmod 755 /var/log/kolla/almanach
|
||||||
|
fi
|
|
@ -0,0 +1,16 @@
|
||||||
|
FROM {{ namespace }}/{{ image_prefix }}almanach-base:{{ tag }}
|
||||||
|
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
|
||||||
|
|
||||||
|
{% block almanach_collector_header %}{% endblock %}
|
||||||
|
|
||||||
|
{% if install_type == 'binary' %}
|
||||||
|
|
||||||
|
RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \
|
||||||
|
&& /bin/false
|
||||||
|
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% block almanach_collector_footer %}{% endblock %}
|
||||||
|
{% block footer %}{% endblock %}
|
||||||
|
|
||||||
|
USER almanach
|
|
@ -95,6 +95,7 @@ _PROFILE_OPTS = [
|
||||||
help='Main images'),
|
help='Main images'),
|
||||||
cfg.ListOpt('aux',
|
cfg.ListOpt('aux',
|
||||||
default=[
|
default=[
|
||||||
|
'almanach',
|
||||||
'aodh',
|
'aodh',
|
||||||
'blazar',
|
'blazar',
|
||||||
'cloudkitty',
|
'cloudkitty',
|
||||||
|
@ -278,6 +279,10 @@ SOURCES = {
|
||||||
'type': 'url',
|
'type': 'url',
|
||||||
'location': ('$tarballs_base/requirements/'
|
'location': ('$tarballs_base/requirements/'
|
||||||
'requirements-master.tar.gz')},
|
'requirements-master.tar.gz')},
|
||||||
|
'almanach-base': {
|
||||||
|
'type': 'url',
|
||||||
|
'location': ('$tarballs_base/almanach/'
|
||||||
|
'almanach-master.tar.gz')},
|
||||||
'aodh-base': {
|
'aodh-base': {
|
||||||
'type': 'url',
|
'type': 'url',
|
||||||
'location': ('$tarballs_base/aodh/'
|
'location': ('$tarballs_base/aodh/'
|
||||||
|
@ -946,6 +951,10 @@ USERS = {
|
||||||
'fluentd-user': {
|
'fluentd-user': {
|
||||||
'uid': 42474,
|
'uid': 42474,
|
||||||
'gid': 42474,
|
'gid': 42474,
|
||||||
|
},
|
||||||
|
'almanach-user': {
|
||||||
|
'uid': 42475,
|
||||||
|
'gid': 42475,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -96,6 +96,7 @@ STATUS_ERRORS = (STATUS_CONNECTION_ERROR, STATUS_PUSH_ERROR,
|
||||||
|
|
||||||
SKIPPED_IMAGES = {
|
SKIPPED_IMAGES = {
|
||||||
'centos+binary': [
|
'centos+binary': [
|
||||||
|
"almanach-base",
|
||||||
"bifrost-base",
|
"bifrost-base",
|
||||||
"blazar-base",
|
"blazar-base",
|
||||||
"dragonflow-base",
|
"dragonflow-base",
|
||||||
|
@ -117,6 +118,7 @@ SKIPPED_IMAGES = {
|
||||||
"ovsdpdk",
|
"ovsdpdk",
|
||||||
],
|
],
|
||||||
'ubuntu+binary': [
|
'ubuntu+binary': [
|
||||||
|
"almanach-base",
|
||||||
"bifrost-base",
|
"bifrost-base",
|
||||||
"blazar-base",
|
"blazar-base",
|
||||||
"cloudkitty-base",
|
"cloudkitty-base",
|
||||||
|
@ -145,6 +147,7 @@ SKIPPED_IMAGES = {
|
||||||
"tripleo-ui"
|
"tripleo-ui"
|
||||||
],
|
],
|
||||||
'debian+binary': [
|
'debian+binary': [
|
||||||
|
"almanach-base",
|
||||||
"bifrost-base",
|
"bifrost-base",
|
||||||
"blazar-base",
|
"blazar-base",
|
||||||
"cloudkitty-base",
|
"cloudkitty-base",
|
||||||
|
@ -175,6 +178,7 @@ SKIPPED_IMAGES = {
|
||||||
"tripleo-ui"
|
"tripleo-ui"
|
||||||
],
|
],
|
||||||
'oraclelinux+binary': [
|
'oraclelinux+binary': [
|
||||||
|
"almanach-base",
|
||||||
"bifrost-base",
|
"bifrost-base",
|
||||||
"blazar-base",
|
"blazar-base",
|
||||||
"dragonflow-base",
|
"dragonflow-base",
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
features:
|
||||||
|
- Almanach Docker images are available in Kolla
|
Loading…
Reference in New Issue