aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils/jailadmin/Makefile
blob: 3a06d2adf6f67dee69af2efbddb9d7dcaa167426 (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
46
# Created by: Kirk Strauser <kirk@strauser.com>
# $FreeBSD$

PORTNAME=   jailadmin
PORTVERSION=    1.9
CATEGORIES= sysutils
MASTER_SITES=   https://BSDforge.com/projects/source/sysutils/jailadmin/

MAINTAINER= portmaster@BSDforge.com
COMMENT=    Jail management system with optional SNMP support

LICENSE=    BSD2CLAUSE

OPTIONS_DEFINE=     SNMP DOCS
SNMP_DESC=  install the additional SNMP management components

USES=       perl5 shebangfix tar:xz
SHEBANG_FILES=  jailadmin jail-snmp jail-snmp-persist

PORTDOCS=   INSTALL README
PLIST_FILES=    etc/jailadmin.conf.sample etc/rc.d/zzz-jail.sh \
        sbin/jailadmin ${SITE_PERL_REL}/Jail.pm

SNMP_LIB_DEPENDS=   libnetsnmp.so:net-mgmt/net-snmp
SNMP_PLIST_FILES=   sbin/jail-snmp sbin/jail-snmp-persist share/snmp/mibs/JAIL-MIB.txt

do-install:
    ${INSTALL_SCRIPT} ${WRKSRC}/jail.sh ${STAGEDIR}${PREFIX}/etc/rc.d/zzz-jail.sh
    ${INSTALL_DATA} ${WRKSRC}/jailadmin.conf.sample ${STAGEDIR}${PREFIX}/etc
    ${INSTALL_SCRIPT} ${WRKSRC}/jailadmin ${STAGEDIR}${PREFIX}/sbin
    @${MKDIR} ${STAGEDIR}${PREFIX}/${SITE_PERL_REL}
    ${CP} ${WRKSRC}/Jail.pm ${STAGEDIR}${PREFIX}/${SITE_PERL_REL}

do-install-SNMP-on:
    ${INSTALL_SCRIPT} ${WRKSRC}/jail-snmp ${STAGEDIR}${PREFIX}/sbin
    ${INSTALL_SCRIPT} ${WRKSRC}/jail-snmp-persist ${STAGEDIR}${PREFIX}/sbin
    @${MKDIR} ${STAGEDIR}${PREFIX}/share/snmp/mibs
    ${INSTALL_DATA} ${WRKSRC}/JAIL-MIB.txt ${STAGEDIR}${PREFIX}/share/snmp/mibs

do-install-DOCS-on:
    @${MKDIR} ${STAGEDIR}${DOCSDIR}
.for i in ${PORTDOCS}
    ${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DOCSDIR}
.endfor

.include <bsd.port.mk>