aboutsummaryrefslogtreecommitdiffstats
path: root/textproc/elasticsearch2-plugin-marvel/Makefile
blob: d21a2948370c14a098a6a076002d252b6f2f0dac (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Created by: Tom Judge <tj@FreeBSD.org>
# $FreeBSD$

PORTNAME=   marvel
PORTVERSION=    2.1.0
PORTREVISION=   1
CATEGORIES= textproc perl5
MASTER_SITES=   http://download.elastic.co/elasticsearch/release/org/elasticsearch/plugin/license/${PORTVERSION}/:source1 \
        http://download.elastic.co/elasticsearch/release/org/elasticsearch/plugin/marvel-agent/${PORTVERSION}/:source2
PKGNAMEPREFIX=  elasticsearch2-plugin-
DISTFILES=  license-${DISTVERSIONPREFIX}${DISTVERSION}${DISTVERSIONSUFFIX}${EXTRACT_SUFX}:source1 \
        marvel-agent-${DISTVERSIONPREFIX}${DISTVERSION}${DISTVERSIONSUFFIX}${EXTRACT_SUFX}:source2

MAINTAINER= dvl@FreeBSD.org
COMMENT=    ElasticSearch Marvel Monitoring Plugin

LICENSE=    COMMERCIAL
LICENSE_NAME=   Free for development; license required for production use
LICENSE_TEXT=   License available from Elasticsearch for production use.
LICENSE_TEXT+=  See http://www.elasticsearch.com/marvel/ for more details.
LICENSE_PERMS=  dist-mirror dist-sell pkg-mirror pkg-sell no-auto-accept

RUN_DEPENDS:=   elasticsearch2>2.0.0:${PORTSDIR}/textproc/elasticsearch2

NO_BUILD=   yes
LEGAL_TEXT= ${LICENSE_NAME_COMMERCIAL}
PLIST_SUB=  VERSION=${PORTVERSION}

USES+=      zip

ZIP_FILES=  license \
    marvel-agent

do-extract:
    @${MKDIR} ${WRKSRC}
.for file in ${ZIP_FILES}
    ( cd ${WRKDIR} && ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} -d ${file}-${PORTVERSION} \
          ${_DISTDIR}/${file}-${DISTVERSIONPREFIX}${DISTVERSION}${DISTVERSIONSUFFIX}${EXTRACT_SUFX} )
.endfor

do-install:
    # while installing, rename marvel-agent to marvel, which is what the plugin expects when running
    @cd ${WRKDIR}/license-${PORTVERSION} && ${COPYTREE_SHARE} . ${STAGEDIR}${PREFIX}/lib/elasticsearch/plugins/license
    @cd ${WRKDIR}/marvel-agent-${PORTVERSION} && ${COPYTREE_SHARE} . ${STAGEDIR}${PREFIX}/lib/elasticsearch/plugins/marvel
.include <bsd.port.mk>