public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-python/flower/, dev-python/flower/files/
@ 2016-03-19  4:20 Zac Medico
  0 siblings, 0 replies; only message in thread
From: Zac Medico @ 2016-03-19  4:20 UTC (permalink / raw
  To: gentoo-commits

commit:     82577e6da88b56df3df491d625a95f52adf99546
Author:     Zac Medico <zmedico <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 19 04:19:33 2016 +0000
Commit:     Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Sat Mar 19 04:20:10 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=82577e6d

dev-python/flower: new package

Package-Manager: portage-2.2.28

 dev-python/flower/Manifest             |   1 +
 dev-python/flower/files/config.py      | 115 +++++++++++++++++++++++++++++++++
 dev-python/flower/files/flower.confd   |   2 +
 dev-python/flower/files/flower.initd   |  24 +++++++
 dev-python/flower/files/flower.service |  13 ++++
 dev-python/flower/flower-0.8.4.ebuild  |  51 +++++++++++++++
 dev-python/flower/metadata.xml         |  10 +++
 7 files changed, 216 insertions(+)

diff --git a/dev-python/flower/Manifest b/dev-python/flower/Manifest
new file mode 100644
index 0000000..bfb3d6f
--- /dev/null
+++ b/dev-python/flower/Manifest
@@ -0,0 +1 @@
+DIST flower-0.8.4.tar.gz 2224949 SHA256 982c2aff14b1b01024cf3356ff90309bc19fba99f47faba3cdb6c3262331c66e SHA512 1f6dc52b011fabff4ea09180338fdc5a155da035daba378a0afb262964bf54bd5d6c90c68ece9a5740ab7e6e99d50e12b566fcd66d6de392163ea859f740f244 WHIRLPOOL 48556c044c7e6ad956288a96066ee985675d7f43116d3a8c749ec1aa3ab7090fb3e061f3e738ea57ef946c5a39e9a8b9290efc4cd8eeb2c8ef6d94a568645e03

diff --git a/dev-python/flower/files/config.py b/dev-python/flower/files/config.py
new file mode 100644
index 0000000..da101ab
--- /dev/null
+++ b/dev-python/flower/files/config.py
@@ -0,0 +1,115 @@
+# Configuration file for the Celery Flower service. Standard Celery
+# configuration settings can be overridden in the configuration file. See the
+# Celery Configuration documentation for a complete listing of all available
+# settings, and their default values.
+
+
+# URL for the broker used by Celery.
+# BROKER_URL = 'amqp://guest:guest@localhost:5672//'
+
+
+# Run the HTTP service on the given address.
+#
+# addess = localhost
+
+
+# Run the HTTP server on the given port.
+#
+# port = 5555
+
+
+# Enables Google OpenID authentication. `auth` is a regexp of emails to grant
+# access. For more info see google-openid.
+#
+# auth = None
+
+
+# Refresh dashboards automatically.
+#
+# auto_refresh = True
+
+
+# Enables HTTP Basic authentication. `basic_auth` is a comma separated list of
+# `username:password`. If configured, any client trying to access this Flower
+# instance will be prompted to provide the credentials specified in this
+# argument.
+#
+# basic_auth = None
+
+
+# Flower can use the RabbitMQ Management Plugin to get info about queues.
+# `broker_api` is a URL of a RabbitMQ HTTP API including user credentials.
+#
+# broker_api = http://username:password@rabbitmq-server-name:15672/api
+
+
+# A path to ca_certs file. The ca_certs file contains a set of concatenated
+# "certification authority" certificates, which are used to validate
+# certificates passed from the other end of the connection.
+#
+# ca_certs = None
+
+
+# A path to an x509 certificate file.
+#
+# certfile = None
+
+
+# A path to the private key for `certfile`.
+#
+# keyfile = None
+
+
+# Enable debug mode.
+#
+# debug = False
+
+
+# Periodically enable Celery events by using `enable_events` command
+#
+# enable_events = True
+
+
+# Modifies the default task formatting. `format_task` should be a function
+# that accepts a task object and returns a modified version. This is useful
+# when filtering out sensitive information.
+#
+# format_task = None
+
+
+# Sets worker inspect timeout in milliseconds.
+#
+# inspect_timeout = 10000
+
+
+# Maximum number of tasks to keep in memory.
+#
+# max_tasks = 10000
+
+
+# Show time relative to the refresh time.
+#
+# natural_time = True
+
+
+# Enable persistent mode. If the persistent mode is enabled, Flower saves the
+# current state and reloads on restart.
+#
+# persistent = False
+
+
+# A path to a database file to use if persistent mode is enabled.
+#
+# db = flower
+
+
+# Enable support of `X-Real-Ip` and `X-Scheme` headers
+#
+# xheaders = False
+
+
+# Specifies list of comma-delimited columns on the /tasks/ page. Order of slugs
+# in the option is unrelated to order of columns on the page. Available slugs
+# include: name, uuid, state, args, kwargs, result, received, started, runtime.
+#
+# tasks_columns = None

diff --git a/dev-python/flower/files/flower.confd b/dev-python/flower/files/flower.confd
new file mode 100644
index 0000000..a74ca17
--- /dev/null
+++ b/dev-python/flower/files/flower.confd
@@ -0,0 +1,2 @@
+# extra arguments for the flower
+command_args="--conf=/etc/flower/config.py"

diff --git a/dev-python/flower/files/flower.initd b/dev-python/flower/files/flower.initd
new file mode 100644
index 0000000..bd2008f
--- /dev/null
+++ b/dev-python/flower/files/flower.initd
@@ -0,0 +1,24 @@
+#!/sbin/openrc-run
+# Copyright 2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+description="Real-time monitor and web admin for Celery distributed task queue"
+pidfile=${pidfile:-"/run/${SVCNAME}/${SVCNAME}.pid"}
+user=${SVCNAME}
+group=${SVCNAME}
+
+command="/usr/bin/${SVCNAME}"
+command_background="true"
+start_stop_daemon_args="--user ${user} --group ${group} \
+	--stdout /var/log/${SVCNAME}/${SVCNAME}.log \
+	--stderr /var/log/${SVCNAME}/${SVCNAME}.log"
+
+depend() {
+	need net
+	after net
+}
+
+start_pre() {
+	checkpath -d -m 0755 -o "${user}":"${group}" "${pidfile%/*}"
+}

diff --git a/dev-python/flower/files/flower.service b/dev-python/flower/files/flower.service
new file mode 100644
index 0000000..5220d89
--- /dev/null
+++ b/dev-python/flower/files/flower.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Real-time monitor and web admin for Celery distributed task queue
+Requires=network-online.target
+After=network-online.target
+
+[Service]
+User=flower
+PrivateDevices=Yes
+Environment=_FLOWER_OPTS="--conf=/etc/flower/config.py"
+ExecStart=/usr/bin/flower $_FLOWER_OPTS
+
+[Install]
+WantedBy=multi-user.target

diff --git a/dev-python/flower/flower-0.8.4.ebuild b/dev-python/flower/flower-0.8.4.ebuild
new file mode 100644
index 0000000..bbbeb2a
--- /dev/null
+++ b/dev-python/flower/flower-0.8.4.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+PYTHON_COMPAT=( python{2_7,3_4} )
+
+inherit distutils-r1 systemd user
+
+DESCRIPTION="Real-time monitor and web admin for Celery distributed task queue"
+HOMEPAGE="https://${PN}.readthedocs.org/ https://github.com/mher/${PN}/ https://pypi.python.org/pypi/${PN}"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+RESTRICT="test"
+
+RDEPEND=">=dev-python/celery-3.1.0[${PYTHON_USEDEP}]
+	>=www-servers/tornado-4.2.0[${PYTHON_USEDEP}]
+	>=dev-python/pytz-2015.7[${PYTHON_USEDEP}]
+	>=dev-python/Babel-2.2.0[${PYTHON_USEDEP}]
+	dev-python/setuptools[${PYTHON_USEDEP}]"
+
+pkg_setup() {
+	enewgroup ${PN}
+	enewuser ${PN} -1 -1 /dev/null ${PN}
+}
+
+src_prepare() {
+	sed -e 's:babel==2.2.0:babel>=2.2.0:' \
+		-e 's:pytz==2015.7:pytz>=2015.7:' \
+		-e 's:tornado==4.2.0:tornado>=4.2.0:' \
+		-i flower.egg-info/requires.txt requirements/default.txt || die
+}
+
+src_install() {
+	distutils-r1_src_install
+	insinto /etc/flower
+	doins "${FILESDIR}/config.py"
+	newinitd "${FILESDIR}/${PN}.initd" "${PN}"
+	newconfd "${FILESDIR}/${PN}.confd" "${PN}"
+	systemd_dounit "${FILESDIR}/${PN}.service"
+	keepdir /var/log/${PN}
+	fowners ${PN}:${PN} /var/log/${PN}
+}
+
+python_test() {
+	esetup.py test || die
+}

diff --git a/dev-python/flower/metadata.xml b/dev-python/flower/metadata.xml
new file mode 100644
index 0000000..cc5d4a1
--- /dev/null
+++ b/dev-python/flower/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+  <maintainer type="person">
+    <email>zmedico@gentoo.org</email>
+  </maintainer>
+  <upstream>
+    <remote-id type="github">mher/flower</remote-id>
+  </upstream>
+</pkgmetadata>


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-03-19  4:20 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-19  4:20 [gentoo-commits] repo/gentoo:master commit in: dev-python/flower/, dev-python/flower/files/ Zac Medico

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox