Lines 1-6
Link Here
|
1 |
PORTNAME= crowdsec |
1 |
PORTNAME= crowdsec |
2 |
PORTVERSION= 1.2.3 # NOTE: change BUILD_VERSION and BUILD_TAG as well |
2 |
PORTVERSION= 1.3.2 # NOTE: change BUILD_VERSION and BUILD_TAG as well |
3 |
PORTREVISION= 1 |
|
|
4 |
DISTVERSIONPREFIX= v |
3 |
DISTVERSIONPREFIX= v |
5 |
CATEGORIES= security |
4 |
CATEGORIES= security |
6 |
|
5 |
|
Lines 15-37
BUILD_DEPENDS= git:devel/git@lite \
Link Here
|
15 |
jq:textproc/jq |
14 |
jq:textproc/jq |
16 |
|
15 |
|
17 |
USES= gmake |
16 |
USES= gmake |
|
|
17 |
ALL_TARGET= build |
18 |
|
18 |
|
19 |
USE_GITHUB= yes |
19 |
USE_GITHUB= yes |
20 |
GH_ACCOUNT= crowdsecurity |
20 |
GH_ACCOUNT= crowdsecurity |
21 |
GH_PROJECT= crowdsec |
21 |
GH_PROJECT= crowdsec |
22 |
GH_TAGNAME= v1.2.3-freebsd |
22 |
GH_TAGNAME= v1.3.2-freebsd-wip |
23 |
#GH_TAGNAME is automatically set from DISTVERSION |
23 |
#GH_TAGNAME is automatically set from DISTVERSION |
24 |
|
24 |
|
|
|
25 |
OPTIONS_DEFINE= FIREWALL_BOUNCER |
26 |
OPTIONS_DEFAULT= |
27 |
|
28 |
FIREWALL_BOUNCER_DESC= Depend on security/crowdsec-firewall-bouncer |
29 |
FIREWALL_BOUNCER_RUN_DEPENDS= crowdsec-firewall-bouncer>=0.0.23.r2:security/crowdsec-firewall-bouncer |
30 |
|
25 |
USE_RC_SUBR= crowdsec |
31 |
USE_RC_SUBR= crowdsec |
26 |
|
32 |
|
27 |
SUB_FILES= pkg-message \ |
33 |
SUB_FILES= pkg-deinstall pkg-install pkg-message |
28 |
pkg-install \ |
|
|
29 |
pkg-deinstall |
30 |
|
34 |
|
31 |
# BUILD_VERSION=$(git describe --tags $(git rev-list --tags --max-count=1)) |
35 |
MAKE_ENV= BUILD_VERSION="v1.3.2" \ |
32 |
# BUILD_TAG=$(git rev-parse HEAD) |
36 |
BUILD_TAG="716251323da59f1ce04fb1fc38af0a72629b5d78" \ |
33 |
MAKE_ENV= BUILD_VERSION="v1.2.3" \ |
37 |
DEFAULT_CONFIGDIR="/usr/local/etc/crowdsec" \ |
34 |
BUILD_TAG="fc4be1e0ffc5888f2824358464cb2426cd4472e1" |
38 |
DEFAULT_DATADIR="/var/db/crowdsec/data" |
35 |
|
39 |
|
36 |
PLUGIN_DIR= ${PREFIX}/lib/crowdsec/plugins |
40 |
PLUGIN_DIR= ${PREFIX}/lib/crowdsec/plugins |
37 |
STAGE_PLUGINS= ${STAGEDIR}${PLUGIN_DIR} |
41 |
STAGE_PLUGINS= ${STAGEDIR}${PLUGIN_DIR} |
Lines 39-55
STAGE_BIN= ${STAGEDIR}${PREFIX}/bin
Link Here
|
39 |
|
43 |
|
40 |
post-patch: |
44 |
post-patch: |
41 |
@${REINPLACE_CMD} 's,/etc/crowdsec/,${ETCDIR}/,g' \ |
45 |
@${REINPLACE_CMD} 's,/etc/crowdsec/,${ETCDIR}/,g' \ |
42 |
${WRKSRC}/pkg/csconfig/config.go \ |
|
|
43 |
${WRKSRC}/pkg/cstest/hubtest_item.go \ |
44 |
${WRKSRC}/cmd/crowdsec-cli/machines.go \ |
45 |
${WRKSRC}/cmd/crowdsec-cli/main.go \ |
46 |
${WRKSRC}/cmd/crowdsec/main.go \ |
47 |
${WRKSRC}/config/config.yaml \ |
46 |
${WRKSRC}/config/config.yaml \ |
48 |
${WRKSRC}/config/profiles.yaml |
47 |
${WRKSRC}/config/profiles.yaml |
49 |
|
48 |
|
50 |
@${REINPLACE_CMD} 's,/var/lib/,/var/db/,g' \ |
49 |
@${REINPLACE_CMD} 's,/var/lib/,/var/db/,g' \ |
51 |
${WRKSRC}/pkg/csconfig/config.go \ |
|
|
52 |
${WRKSRC}/pkg/metabase/database.go \ |
53 |
${WRKSRC}/config/config.yaml \ |
50 |
${WRKSRC}/config/config.yaml \ |
54 |
${WRKSRC}/config/profiles.yaml |
51 |
${WRKSRC}/config/profiles.yaml |
55 |
|
52 |
|
Lines 81-86
do-install:
Link Here
|
81 |
@${MV} ${STAGEDIR}${ETCDIR}/config.yaml \ |
78 |
@${MV} ${STAGEDIR}${ETCDIR}/config.yaml \ |
82 |
${STAGEDIR}${ETCDIR}/config.yaml.sample |
79 |
${STAGEDIR}${ETCDIR}/config.yaml.sample |
83 |
|
80 |
|
|
|
81 |
@${MV} ${STAGEDIR}${ETCDIR}/console.yaml \ |
82 |
${STAGEDIR}${ETCDIR}/console.yaml.sample |
83 |
|
84 |
@${MV} ${STAGEDIR}${ETCDIR}/profiles.yaml \ |
84 |
@${MV} ${STAGEDIR}${ETCDIR}/profiles.yaml \ |
85 |
${STAGEDIR}${ETCDIR}/profiles.yaml.sample |
85 |
${STAGEDIR}${ETCDIR}/profiles.yaml.sample |
86 |
|
86 |
|
Lines 96-114
do-install:
Link Here
|
96 |
|
96 |
|
97 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/email |
97 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/email |
98 |
@${MV} ${WRKSRC}/plugins/notifications/email/email.yaml \ |
98 |
@${MV} ${WRKSRC}/plugins/notifications/email/email.yaml \ |
99 |
${STAGEDIR}${ETCDIR}/notifications/email/email.yaml.sample |
99 |
${STAGEDIR}${ETCDIR}/notifications/email.yaml.sample |
100 |
|
100 |
|
101 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/http |
101 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/http |
102 |
@${MV} ${WRKSRC}/plugins/notifications/http/http.yaml \ |
102 |
@${MV} ${WRKSRC}/plugins/notifications/http/http.yaml \ |
103 |
${STAGEDIR}${ETCDIR}/notifications/http/http.yaml.sample |
103 |
${STAGEDIR}${ETCDIR}/notifications/http.yaml.sample |
104 |
|
104 |
|
105 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/slack |
105 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/slack |
106 |
@${MV} ${WRKSRC}/plugins/notifications/slack/slack.yaml \ |
106 |
@${MV} ${WRKSRC}/plugins/notifications/slack/slack.yaml \ |
107 |
${STAGEDIR}${ETCDIR}/notifications/slack/slack.yaml.sample |
107 |
${STAGEDIR}${ETCDIR}/notifications/slack.yaml.sample |
108 |
|
108 |
|
109 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/splunk |
109 |
@${MKDIR} ${STAGEDIR}${ETCDIR}/notifications/splunk |
110 |
@${MV} ${WRKSRC}/plugins/notifications/splunk/splunk.yaml \ |
110 |
@${MV} ${WRKSRC}/plugins/notifications/splunk/splunk.yaml \ |
111 |
${STAGEDIR}${ETCDIR}/notifications/splunk/splunk.yaml.sample |
111 |
${STAGEDIR}${ETCDIR}/notifications/splunk.yaml.sample |
112 |
|
112 |
|
113 |
# updated by "cscli machines" at first service start |
113 |
# updated by "cscli machines" at first service start |
114 |
@${MV} ${STAGEDIR}${ETCDIR}/local_api_credentials.yaml \ |
114 |
@${MV} ${STAGEDIR}${ETCDIR}/local_api_credentials.yaml \ |
Lines 130-135
do-install:
Link Here
|
130 |
# |
130 |
# |
131 |
|
131 |
|
132 |
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR} |
132 |
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR} |
133 |
${INSTALL_DATA} ${FILESDIR}/crowdsec.conf-newsyslog ${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d/crowdsec.conf.sample |
|
|
134 |
|
133 |
|
135 |
.include <bsd.port.mk> |
134 |
.include <bsd.port.mk> |