Add ptp service docker image

Change-Id: I317ae1fe3bb33cda4e5b947e5418f9419373d7c5
Partial-implements: blueprint ptp-service
This commit is contained in:
Zenghui Shi 2017-11-09 19:32:46 +08:00
parent ec028fc398
commit 725c14c43e
5 changed files with 34 additions and 0 deletions

View File

@ -148,6 +148,8 @@ Kolla provides images to deploy the following infrastructure components:
- `MongoDB <https://www.mongodb.org/>`__ as a database back end for Ceilometer
and Gnocchi.
- `Open vSwitch <http://openvswitch.org/>`__ and Linuxbridge back ends for Neutron.
- `Linuxptp <http://linuxptp.sourceforge.net/>`__ an implementation of the Precision
Time Protocol (PTP) according to IEEE standard 1588 for Linux.
- `Qdrouterd <https://qpid.apache.org/components/dispatch-router/index.html>`__ as a
direct messaging back end for communication between services.
- `RabbitMQ <https://www.rabbitmq.com/>`__ as a broker messaging back end for

16
docker/ptp/Dockerfile.j2 Normal file
View File

@ -0,0 +1,16 @@
FROM {{ namespace }}/{{ image_prefix }}base:{{ tag }}
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
{% block ptp_header %}{% endblock %}
{% import "macros.j2" as macros with context %}
{% set ptp_packages = ['linuxptp'] %}
{{ macros.install_packages(ptp_packages | customizable("packages")) }}
COPY extend_start.sh /usr/local/bin/kolla_extend_start
RUN chmod 755 /usr/local/bin/kolla_extend_start
{% block ptp_footer %}{% endblock %}
{% block footer %}{% endblock %}

View File

@ -0,0 +1,12 @@
#!/bin/bash
rm -f /var/run/ptp.pid
PTP_LOG_DIR="/var/log/kolla/ptp"
if [[ ! -d "${PTP_LOG_DIR}" ]]; then
mkdir -p ${PTP_LOG_DIR}
fi
if [[ $(stat -c %a ${PTP_LOG_DIR}) != "755" ]]; then
chmod 755 ${PTP_LOG_DIR}
fi

View File

@ -71,6 +71,7 @@ _PROFILE_OPTS = [
'mongodb',
'opendaylight',
'openvswitch',
'ptp',
'qdrouterd',
'rabbitmq',
'redis',

View File

@ -0,0 +1,3 @@
---
features:
- Add ptp service image