mirror of
https://github.com/zeek/zeek.git
synced 2025-10-07 17:18:20 +00:00
Updates for the build system and site local scripts for cluster.
This commit is contained in:
parent
8e7a76b548
commit
6f50e362db
8 changed files with 35 additions and 6 deletions
|
@ -1,18 +1,27 @@
|
||||||
include(InstallPackageConfigFile)
|
include(InstallPackageConfigFile)
|
||||||
|
|
||||||
install(DIRECTORY ./ DESTINATION ${POLICYDIR} FILES_MATCHING
|
install(DIRECTORY ./ DESTINATION ${POLICYDIR} FILES_MATCHING
|
||||||
PATTERN "all.bro" EXCLUDE
|
PATTERN "site/local*" EXCLUDE
|
||||||
PATTERN "site/local.bro" EXCLUDE
|
|
||||||
PATTERN "bro.init"
|
|
||||||
PATTERN "*.bro"
|
PATTERN "*.bro"
|
||||||
PATTERN "*.sig"
|
PATTERN "*.sig"
|
||||||
PATTERN "*.osf"
|
PATTERN "*.fp"
|
||||||
)
|
)
|
||||||
|
|
||||||
# Install as a config file since the local.bro script is meant to be
|
# Install all local* scripts as config files since they are meant to be
|
||||||
# user modify-able.
|
# user modify-able.
|
||||||
InstallPackageConfigFile(
|
InstallPackageConfigFile(
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}/site/local.bro
|
${CMAKE_CURRENT_SOURCE_DIR}/site/local.bro
|
||||||
${POLICYDIR}/site
|
${POLICYDIR}/site
|
||||||
local.bro)
|
local.bro)
|
||||||
|
InstallPackageConfigFile(
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/site/local-manager.bro
|
||||||
|
${POLICYDIR}/site
|
||||||
|
local-manager.bro)
|
||||||
|
InstallPackageConfigFile(
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/site/local-proxy.bro
|
||||||
|
${POLICYDIR}/site
|
||||||
|
local-proxy.bro)
|
||||||
|
InstallPackageConfigFile(
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/site/local-worker.bro
|
||||||
|
${POLICYDIR}/site
|
||||||
|
local-worker.bro)
|
||||||
|
|
|
@ -10,6 +10,9 @@
|
||||||
|
|
||||||
@prefixes += cluster-manager
|
@prefixes += cluster-manager
|
||||||
|
|
||||||
|
## Load the script for local site configuration for the manager node.
|
||||||
|
@load site/local-manager
|
||||||
|
|
||||||
## Turn off remote logging since this is the manager and should only log here.
|
## Turn off remote logging since this is the manager and should only log here.
|
||||||
redef Log::enable_remote_logging = F;
|
redef Log::enable_remote_logging = F;
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,9 @@
|
||||||
|
|
||||||
@prefixes += cluster-proxy
|
@prefixes += cluster-proxy
|
||||||
|
|
||||||
|
## Load the script for local site configuration for proxy nodes.
|
||||||
|
@load site/local-proxy
|
||||||
|
|
||||||
## The proxy only syncs state; does not forward events.
|
## The proxy only syncs state; does not forward events.
|
||||||
redef forward_remote_events = F;
|
redef forward_remote_events = F;
|
||||||
redef forward_remote_state_changes = T;
|
redef forward_remote_state_changes = T;
|
||||||
|
|
|
@ -1,6 +1,9 @@
|
||||||
|
|
||||||
@prefixes += cluster-worker
|
@prefixes += cluster-worker
|
||||||
|
|
||||||
|
## Load the script for local site configuration for the worker nodes.
|
||||||
|
@load site/local-worker
|
||||||
|
|
||||||
## Don't do any local logging.
|
## Don't do any local logging.
|
||||||
redef Log::enable_local_logging = F;
|
redef Log::enable_local_logging = F;
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
|
||||||
module Cluster;
|
module Cluster;
|
||||||
|
|
||||||
event bro_init() &priority=9
|
event bro_init() &priority=9
|
||||||
|
|
7
scripts/site/local-manager.bro
Normal file
7
scripts/site/local-manager.bro
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
##! Local site policy loaded only by the manager in a cluster.
|
||||||
|
|
||||||
|
# If you are running a cluster you should define your Notice::policy here
|
||||||
|
# so that notice processing occurs on the manager.
|
||||||
|
redef Notice::policy += {
|
||||||
|
|
||||||
|
};
|
2
scripts/site/local-proxy.bro
Normal file
2
scripts/site/local-proxy.bro
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
##! Local site policy loaded only by the proxies if Bro is running as a cluster.
|
||||||
|
|
1
scripts/site/local-worker.bro
Normal file
1
scripts/site/local-worker.bro
Normal file
|
@ -0,0 +1 @@
|
||||||
|
##! Local site policy loaded only by the workers if Bro is running as a cluster.
|
Loading…
Add table
Add a link
Reference in a new issue