diff options
author | Stuart Mackie <wsmackie@juniper.net> | 2017-03-23 06:19:54 -0700 |
---|---|---|
committer | Stuart Mackie <wsmackie@juniper.net> | 2017-03-23 06:19:54 -0700 |
commit | 88df88a19674ccc0017836941b8ee32eaadf19fb (patch) | |
tree | f930c90f75846ec8d8e33cf27325ff8fafc85d5c /charms/trusty/kafka/actions/write-topic | |
parent | 9f50a40437477432a21b326b15c343ca6b8fe516 (diff) |
Deleted charms with wrong license. Will source them differently in future.
Change-Id: I0fc99ea03c6b6ca4701e63793cb2be60e56c7588
Signed-off-by: Stuart Mackie <wsmackie@juniper.net>
Diffstat (limited to 'charms/trusty/kafka/actions/write-topic')
-rwxr-xr-x | charms/trusty/kafka/actions/write-topic | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/charms/trusty/kafka/actions/write-topic b/charms/trusty/kafka/actions/write-topic deleted file mode 100755 index fce8e1b..0000000 --- a/charms/trusty/kafka/actions/write-topic +++ /dev/null @@ -1,36 +0,0 @@ -#!/usr/bin/env python -#pylint: disable=C0103 - -try: - from charmhelpers.core import hookenv - from charmhelpers.core import unitdata - import jujubigdata - from jujubigdata import utils - charm_ready = unitdata.kv().get('charm.active', False) -except ImportError: - charm_ready = False - -if not charm_ready: - # might not have hookenv.action_fail available yet - from subprocess import call - call(['action-fail', 'Kafka service not yet ready']) - - -kafka_reqs = ['vendor', 'packages', 'groups', 'users', 'dirs', 'ports'] -dist_config = jujubigdata.utils.DistConfig(filename='dist.yaml', - required_keys=kafka_reqs) - -# Grab the business -topic_name = hookenv.action_get('topic') -data = hookenv.action_get('data') - -output = utils.run_as( - 'kafka', 'kafka-console-producer.sh', - '--broker-list', '{}:{}'.format( - hookenv.unit_private_ip(), - dist_config.port('kafka'), - ), - '--topic', topic_name, - capture_output=True, - input=data) -hookenv.action_set({'output': output}) |