diff --git a/README.md b/README.md index 2196718b..57438f1f 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ -**Praeco** is an alerting tool for Elasticsearch – a GUI for [Elastalert 2](https://github.com/jertel/elastalert2), using the [Elastalert API](https://github.com/johnsusek/elastalert-server). +**Praeco** is an alerting tool for Elasticsearch – a GUI for [ElastAlert 2](https://github.com/jertel/elastalert2), using the [ElastAlert API](https://github.com/johnsusek/elastalert-server). - Interactively build alerts for your Elasticsearch data using a query builder - Preview results in an interactive chart @@ -63,14 +63,14 @@ You may need to update your config files when a new version comes out. Please se ## Configuration -Edit `rules/BaseRule.config`, `config/api.config.json`, `config/elastalert.yaml`, and/or `public/praeco.config.json` for advanced configuration options. See the [api docs](https://github.com/johnsusek/elastalert-server#configuration) and the [example Elastalert 2 config](https://github.com/jertel/elastalert/blob/alt/config.yaml.example) for more information. +Edit `rules/BaseRule.config`, `config/api.config.json`, `config/elastalert.yaml`, and/or `public/praeco.config.json` for advanced configuration options. See the [api docs](https://github.com/johnsusek/elastalert-server#configuration) and the [example ElastAlert 2 config](https://github.com/jertel/elastalert/blob/alt/config.yaml.example) for more information. -Any Elastalert 2 option you put into `rules/BaseRule.config` will be applied to every rule. +Any ElastAlert 2 option you put into `rules/BaseRule.config` will be applied to every rule. The following config settings are available in praeco.config.json: ``` -// Link back to your praeco instance, used in Slack alerts +// Link back to your Praeco instance, used in Slack alerts "appUrl": "http://praeco-app-url:8080", // A recordatus (https://github.com/johnsusek/recordatus) instance for javascript error reporting @@ -85,13 +85,13 @@ The following config settings are available in praeco.config.json: [ElastAlert Server](https://hub.docker.com/r/praecoapp/elastalert-server) -[praeco & elastalert server docker image relations table](https://github.com/johnsusek/praeco/wiki/praeco-&-elastalert-server-docker-image-relations-table) +[Praeco & elastalert server docker image relations table](https://github.com/johnsusek/praeco/wiki/praeco-&-elastalert-server-docker-image-relations-table) [praecoapp/elastalert-server ChangeLog](https://github.com/johnsusek/elastalert-server/blob/master/DockerImageLog.md) ## FAQ -#### Is there a sample to start elasticsearch, kibana, elastalert-server, praeco with docker-compose? +#### Is there a sample to start elasticsearch, kibana, elastalert-server, Praeco with docker-compose? [docker compose sample(telegram)](https://github.com/johnsusek/praeco/wiki/docker-compose-sample(telegram)) @@ -99,7 +99,7 @@ The following config settings are available in praeco.config.json: 👉 [ElastAlert 2 Alerts support status](https://github.com/johnsusek/praeco/wiki/ElastAlert-2-Alerts-support-status) -#### Will elastalert-server / praeco be supported forever? +#### Will elastalert-server / Praeco be supported forever? First of all, please understand that it is open source software. If you need generous support, please consider paid support software. @@ -121,6 +121,26 @@ Not Support Not Support +#### Does elastalert-server support Amazon Elasticsearch Service? + +Not Support + +#### Does elastalert-server support Elastic Cloud Cloud ID? + +Not Support + +#### Does elastalert-server support Elasticsearch ApiKey authentication connections? + +Not Support + +#### Does elastalert-server support Elasticsearch Bearer authentication connections? + +Not Support + +#### Does elastalert-server support Elasticsearch proxy connections? + +Not Support + #### Mulit-elasticsearch instances Not Support @@ -141,10 +161,10 @@ There are no plans to support this at this time. There are no plans to support this at this time. -#### I can't send an email when I specify a gmail or office365 address in from_addr of Email. Is there a workaround? +#### I can't send an email when I specify a gmail or Microsoft 365 address in from_addr of Email. Is there a workaround? - For Gmail, you need to set Allow insecure apps. -- There is no workaround for office365. +- There is no workaround for Microsoft 365. #### Is it possible to raise an alert only during a specific time period? @@ -178,13 +198,17 @@ It can be set with Limit Excecution. [Praeco Helm Chart](https://github.com/daichi703n/praeco-helm)
[Installing Praeco (ElastAlert GUI) into Kubernetes with Helm](https://en-designetwork.daichi703n.com/entry/2020/02/24/praeco-helm-kubernetes) -#### How do I connect to elasticsearch using SSL? +#### How do I change ElastAlert 2 options, like SSL, user/pass, etc? + +Edit `config/elastalert.yaml` and uncomment the appropriate lines. + +#### [elastalert-server] How do I connect to elasticsearch using SSL? Edit `config/api.config.json` and set/add `"es_ssl": true`.
option `"es_ca_certs"`, `"es_client_cert"`, `"es_client_key"`.
[configuration](https://github.com/johnsusek/elastalert-server#configuration) -#### How do I connect to elasticsearch with a username and password? +#### [elastalert-server] How do I connect to elasticsearch with a username and password? Edit `es_username` and `es_password` in `config/api.config.json` and `config/elastalert.yaml`. @@ -207,10 +231,6 @@ rewrite ^/my-path(/.*)$ $1 last; Edit `config/elastalert.yaml` and `config/api.config.json` and change the writeback_index values. -#### How do I change elastalert 2 options, like SSL, user/pass, etc? - -Edit `config/elastalert.yaml` and uncomment the appropriate lines. - #### How do I run this on Windows? First, install docker and docker-compose. @@ -224,9 +244,9 @@ docker-compose.exe up Replace 1.2.3.4 with your Elasticsearch IP. -#### Can I import my current elastalert 2 rules into praeco? +#### Can I import my current ElastAlert 2 rules into praeco? -Unfortunately this is not a possibility for two reasons. First, praeco only supports a subset of elastalert 2 features, so only certain rules would work. Second, praeco cannot automatically create the query builder ui from an arbitrary elastalert 2 `filter` entry, due to the potential complexity and combinations of filters someone can put in their rule file. +Unfortunately this is not a possibility for two reasons. First, praeco only supports a subset of ElastAlert 2 features, so only certain rules would work. Second, praeco cannot automatically create the query builder ui from an arbitrary ElastAlert 2 `filter` entry, due to the potential complexity and combinations of filters someone can put in their rule file. #### Can I export my praeco rules into another elastalert 2 instance? @@ -260,7 +280,7 @@ First of all, try to test your alert with varying time frames and see if that is If the test is returning results, but you are not receiving any alerts, check the error log. There may be a problem with your alerter settings. Make sure you edited rules/BaseRule.config and have correct values in there. -If the test is not returning results, even though you think it should, try reading the [elastalert 2 docs](https://elastalert2.readthedocs.io/en/latest/ruletypes.html#rule-types) for your rule type. Compare the yaml from praeco with the options from the docs to make sure the rule is being created as expected. If praeco is generating the wrong yaml, please file an issue. +If the test is not returning results, even though you think it should, try reading the [ElastAlert 2 docs](https://elastalert2.readthedocs.io/en/latest/ruletypes.html#rule-types) for your rule type. Compare the yaml from praeco with the options from the docs to make sure the rule is being created as expected. If praeco is generating the wrong yaml, please file an issue. #### Failed to establish a new connection: [Errno 111] Connection refused @@ -376,25 +396,25 @@ Please see https://elastalert2.readthedocs.io/en/latest/ruletypes.html#jira for ![](https://user-images.githubusercontent.com/611996/52892144-90a19300-3155-11e9-8050-cb4a440411a4.png) -Praeco is a vue.js app (hosted in an nginx docker container) that communicates with the [Elastalert API](https://github.com/johnsusek/elastalert-server) (running in another docker container) to view/edit rules. -The elastalert api interacts with the included [Elastalert 2](https://github.com/jertel/elastalert2) python daemon directly for various tasks including testing and silencing rules, and indirectly by modifying or creating +Praeco is a vue.js app (hosted in an nginx docker container) that communicates with the [ElastAlert API](https://github.com/johnsusek/elastalert-server) (running in another docker container) to view/edit rules. +The elastalert api interacts with the included [ElastAlert 2](https://github.com/jertel/elastalert2) python daemon directly for various tasks including testing and silencing rules, and indirectly by modifying or creating rule files in the rules/ directory. When you run praeco using the quickstart instructions, it runs these two docker containers, per the docker-compose.yml file. Praeco uses a fork of the elastalert _api server_, which is why the docker image source is [johnsusek/elastalert-server](https://github.com/johnsusek/elastalert-server). -NOTE: Only the _api server_ is a fork, the elastalert 2 daemon itself is built from the `master` branch whenever a new version of the `johnsusek/elastalert-server` docker image is created. +NOTE: Only the _api server_ is a fork, the ElastAlert 2 daemon itself is built from the `master` branch whenever a new version of the `johnsusek/elastalert-server` docker image is created. Please see the development section below if you're interested in running these services separately. ## Manual/Dev installation -NOTE: If you're just interested in developing Praeco UI features locally (and not changing elastalert 2 or the api), you can skip right to Praeco setup and just run the internal Elastalert server with `docker-compose up elastalert-server` . +NOTE: If you're just interested in developing Praeco UI features locally (and not changing ElastAlert 2 or the api), you can skip right to Praeco setup and just run the internal Elastalert server with `docker-compose up elastalert-server` . --- -First, you need a local copy of the elastalert api server running, which itself needs elastalert 2. Start by cloning the neccessary repos +First, you need a local copy of the elastalert api server running, which itself needs ElastAlert 2. Start by cloning the neccessary repos ```sh $ cd @@ -403,7 +423,7 @@ $ git clone https://github.com/johnsusek/elastalert-server.git $ git clone https://github.com/johnsusek/praeco.git ``` -### Setting up Elastalert 2 +### Setting up ElastAlert 2 **Python Support version** @@ -415,7 +435,7 @@ $ git clone https://github.com/johnsusek/praeco.git I think it works with 6.x, but I haven't confirmed the operation. -Configure the elastalert 2 `config.yaml` with: +Configure the ElastAlert 2 `config.yaml` with: - Your `es_host` - A unique `writeback_index` - Change the rules_folder to `rules` @@ -434,7 +454,7 @@ vi config.yaml ### Setting up the API server Configure the api server `config.json` with: -- An _absolute path_ to your elastalert 2 folder for `elastalertPath` +- An _absolute path_ to your ElastAlert 2 folder for `elastalertPath` - The address of your elasticsearch instance for `es_host` - The same `writeback_index` from the config.yaml diff --git a/config/elastalert.yaml b/config/elastalert.yaml index efc230f5..02cdd1c6 100644 --- a/config/elastalert.yaml +++ b/config/elastalert.yaml @@ -9,12 +9,12 @@ es_port: 9200 # Any .yaml file will be loaded as a rule rules_folder: rules -# How often ElastAlert will query elasticsearch +# How often ElastAlert 2 will query elasticsearch # The unit can be anything from weeks to seconds run_every: seconds: 60 -# ElastAlert will buffer results from the most recent +# ElastAlert 2 will buffer results from the most recent # period of time, in case some log sources are not in real time buffer_time: minutes: 1 diff --git a/package.json b/package.json index 9dfe5dd3..7f6bae4e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "praeco", - "version": "1.8.8", + "version": "1.8.9", "private": true, "scripts": { "serve": "vue-cli-service serve", diff --git a/src/components/FolderTree.vue b/src/components/FolderTree.vue index a38b3d00..b7f6e62e 100644 --- a/src/components/FolderTree.vue +++ b/src/components/FolderTree.vue @@ -15,8 +15,8 @@ diff --git a/src/components/config/ConfigScanEntireTimeframe.vue b/src/components/config/ConfigScanEntireTimeframe.vue new file mode 100644 index 00000000..8308f78b --- /dev/null +++ b/src/components/config/ConfigScanEntireTimeframe.vue @@ -0,0 +1,48 @@ + + + diff --git a/src/components/config/alert/ConfigAlert.vue b/src/components/config/alert/ConfigAlert.vue index 1d643350..b4a21344 100644 --- a/src/components/config/alert/ConfigAlert.vue +++ b/src/components/config/alert/ConfigAlert.vue @@ -35,56 +35,49 @@ - + + - - - - - + + + - - -
-
- {{ limitExcecution }} -
-
- {{ limitExcecution }} -
-
+ + + + + - + + + + @@ -113,10 +106,10 @@ Telegram - JIRA + Jira - GOOGLE CHAT + Google Chat LineNotify @@ -194,3690 +187,296 @@ class="m-s-lg" /> + - - - - - - - - - - - - - - - - - - Danger - - - Warning - - - Good - - - - - - - - none - - - full - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + Email - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + HTTP - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - + + - - - - - - - - - basic - - - card - - - - -
- - - - - - - - - - - - - - - - - - - -
+
+ - - - - - + + - - - - - - - - - - - - - - Danger - - - Warning - - - Good - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - Command ({{ command.length }}) - - Command ({{ command.length }}) - - - - - - - - - - - - - + + - - - - - - - - - - Error - - - Info - - - - - - - - + + - - Profile - - - NotProfile - - -
- - - - - - - - - - - - - - - - -
-
- - - - - - - - -
+
+ - - - Profile - - - NotProfile - - -
- - - - - - - - - - - - -
-
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
+ - - - - - - - - - - - - - - - - - - - + + - - SMS - - - Copilot - - - - - - - - - - - - - - - - - -
- - - - -
- -
- - - - -
+
+ - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - INFO - - - WARNING - - - ACKNOWLEDGEMENT - - - CRITICAL - - - RECOVERY - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Tags ({{ hiveAlertConfigTags.length }}) - - Tags ({{ hiveAlertConfigTags.length }}) - - - - - - - - - - - - - Waiting - - - InProgress - - - Cancel - - - Completed - - - - - - - - + + + + - - - - + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Tags ({{ alertaTags.length }}) - - Tags ({{ alertaTags.length }}) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Danger - - - Warning - - - Good - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + diff --git a/src/components/config/alert/ConfigAlertAmazonSes.vue b/src/components/config/alert/ConfigAlertAmazonSes.vue new file mode 100644 index 00000000..2e18aaf7 --- /dev/null +++ b/src/components/config/alert/ConfigAlertAmazonSes.vue @@ -0,0 +1,284 @@ +. + + + + diff --git a/src/components/config/alert/ConfigAlertAmazonSns.vue b/src/components/config/alert/ConfigAlertAmazonSns.vue new file mode 100644 index 00000000..5a63e72b --- /dev/null +++ b/src/components/config/alert/ConfigAlertAmazonSns.vue @@ -0,0 +1,136 @@ +. + + + + diff --git a/src/components/config/alert/ConfigAlertChatwork.vue b/src/components/config/alert/ConfigAlertChatwork.vue new file mode 100644 index 00000000..0d8a43a8 --- /dev/null +++ b/src/components/config/alert/ConfigAlertChatwork.vue @@ -0,0 +1,65 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertCommand.vue b/src/components/config/alert/ConfigAlertCommand.vue new file mode 100644 index 00000000..5042e8a6 --- /dev/null +++ b/src/components/config/alert/ConfigAlertCommand.vue @@ -0,0 +1,191 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertDatadog.vue b/src/components/config/alert/ConfigAlertDatadog.vue new file mode 100644 index 00000000..5345fdfa --- /dev/null +++ b/src/components/config/alert/ConfigAlertDatadog.vue @@ -0,0 +1,57 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertDiscord.vue b/src/components/config/alert/ConfigAlertDiscord.vue new file mode 100644 index 00000000..dc4725ac --- /dev/null +++ b/src/components/config/alert/ConfigAlertDiscord.vue @@ -0,0 +1,163 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertEmail.vue b/src/components/config/alert/ConfigAlertEmail.vue new file mode 100644 index 00000000..a7006549 --- /dev/null +++ b/src/components/config/alert/ConfigAlertEmail.vue @@ -0,0 +1,310 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertExotel.vue b/src/components/config/alert/ConfigAlertExotel.vue new file mode 100644 index 00000000..b89b3bae --- /dev/null +++ b/src/components/config/alert/ConfigAlertExotel.vue @@ -0,0 +1,113 @@ +. + + + + diff --git a/src/components/config/alert/ConfigAlertGitter.vue b/src/components/config/alert/ConfigAlertGitter.vue new file mode 100644 index 00000000..a0e0e15b --- /dev/null +++ b/src/components/config/alert/ConfigAlertGitter.vue @@ -0,0 +1,136 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertGoogleChat.vue b/src/components/config/alert/ConfigAlertGoogleChat.vue new file mode 100644 index 00000000..0cd905c2 --- /dev/null +++ b/src/components/config/alert/ConfigAlertGoogleChat.vue @@ -0,0 +1,138 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertHttpPost.vue b/src/components/config/alert/ConfigAlertHttpPost.vue new file mode 100644 index 00000000..e6a99683 --- /dev/null +++ b/src/components/config/alert/ConfigAlertHttpPost.vue @@ -0,0 +1,104 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertJira.vue b/src/components/config/alert/ConfigAlertJira.vue new file mode 100644 index 00000000..bdb6b7c7 --- /dev/null +++ b/src/components/config/alert/ConfigAlertJira.vue @@ -0,0 +1,78 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertLineNotify.vue b/src/components/config/alert/ConfigAlertLineNotify.vue new file mode 100644 index 00000000..d8ec2125 --- /dev/null +++ b/src/components/config/alert/ConfigAlertLineNotify.vue @@ -0,0 +1,46 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertMattermost.vue b/src/components/config/alert/ConfigAlertMattermost.vue new file mode 100644 index 00000000..6f574159 --- /dev/null +++ b/src/components/config/alert/ConfigAlertMattermost.vue @@ -0,0 +1,430 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertMsTeams.vue b/src/components/config/alert/ConfigAlertMsTeams.vue new file mode 100644 index 00000000..c5fcdef4 --- /dev/null +++ b/src/components/config/alert/ConfigAlertMsTeams.vue @@ -0,0 +1,145 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertPagerTree.vue b/src/components/config/alert/ConfigAlertPagerTree.vue new file mode 100644 index 00000000..a03c9aed --- /dev/null +++ b/src/components/config/alert/ConfigAlertPagerTree.vue @@ -0,0 +1,89 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertRocketChat.vue b/src/components/config/alert/ConfigAlertRocketChat.vue new file mode 100644 index 00000000..5693b16b --- /dev/null +++ b/src/components/config/alert/ConfigAlertRocketChat.vue @@ -0,0 +1,362 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertServiceNow.vue b/src/components/config/alert/ConfigAlertServiceNow.vue new file mode 100644 index 00000000..50962b0b --- /dev/null +++ b/src/components/config/alert/ConfigAlertServiceNow.vue @@ -0,0 +1,257 @@ +. + + + + diff --git a/src/components/config/alert/ConfigAlertSlack.vue b/src/components/config/alert/ConfigAlertSlack.vue new file mode 100644 index 00000000..d3e0fc2a --- /dev/null +++ b/src/components/config/alert/ConfigAlertSlack.vue @@ -0,0 +1,549 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertStomp.vue b/src/components/config/alert/ConfigAlertStomp.vue new file mode 100644 index 00000000..8bab617b --- /dev/null +++ b/src/components/config/alert/ConfigAlertStomp.vue @@ -0,0 +1,141 @@ +. + + + + diff --git a/src/components/config/alert/ConfigAlertTelegram.vue b/src/components/config/alert/ConfigAlertTelegram.vue new file mode 100644 index 00000000..2b7d002d --- /dev/null +++ b/src/components/config/alert/ConfigAlertTelegram.vue @@ -0,0 +1,101 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertTheHive.vue b/src/components/config/alert/ConfigAlertTheHive.vue new file mode 100644 index 00000000..b8ac8c66 --- /dev/null +++ b/src/components/config/alert/ConfigAlertTheHive.vue @@ -0,0 +1,273 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertTwilio.vue b/src/components/config/alert/ConfigAlertTwilio.vue new file mode 100644 index 00000000..6b072b72 --- /dev/null +++ b/src/components/config/alert/ConfigAlertTwilio.vue @@ -0,0 +1,132 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertVictorOps.vue b/src/components/config/alert/ConfigAlertVictorOps.vue new file mode 100644 index 00000000..d0bda66e --- /dev/null +++ b/src/components/config/alert/ConfigAlertVictorOps.vue @@ -0,0 +1,155 @@ + + + + + diff --git a/src/components/config/alert/ConfigAlertZabbix.vue b/src/components/config/alert/ConfigAlertZabbix.vue new file mode 100644 index 00000000..5b6f84f3 --- /dev/null +++ b/src/components/config/alert/ConfigAlertZabbix.vue @@ -0,0 +1,95 @@ + + + + + diff --git a/src/registration.js b/src/registration.js index b6c2e84a..beea9036 100644 --- a/src/registration.js +++ b/src/registration.js @@ -14,6 +14,32 @@ import ElastalertTimeView from '@/components/ElastalertTimeView'; import ConfigQuery from '@/components/config/ConfigQuery.vue'; import ConfigAggregation from '@/components/config/ConfigAggregation.vue'; import ConfigAlert from '@/components/config/alert/ConfigAlert.vue'; +import ConfigAlertAlerta from '@/components/config/alert/ConfigAlertAlerta.vue'; +import ConfigAlertAmazonSes from '@/components/config/alert/ConfigAlertAmazonSes.vue'; +import ConfigAlertAmazonSns from '@/components/config/alert/ConfigAlertAmazonSns.vue'; +import ConfigAlertChatwork from '@/components/config/alert/ConfigAlertChatwork.vue'; +import ConfigAlertCommand from '@/components/config/alert/ConfigAlertCommand.vue'; +import ConfigAlertDatadog from '@/components/config/alert/ConfigAlertDatadog.vue'; +import ConfigAlertDiscord from '@/components/config/alert/ConfigAlertDiscord.vue'; +import ConfigAlertEmail from '@/components/config/alert/ConfigAlertEmail.vue'; +import ConfigAlertExotel from '@/components/config/alert/ConfigAlertExotel.vue'; +import ConfigAlertGitter from '@/components/config/alert/ConfigAlertGitter.vue'; +import ConfigAlertGoogleChat from '@/components/config/alert/ConfigAlertGoogleChat.vue'; +import ConfigAlertHttpPost from '@/components/config/alert/ConfigAlertHttpPost.vue'; +import ConfigAlertJira from '@/components/config/alert/ConfigAlertJira.vue'; +import ConfigAlertLineNotify from '@/components/config/alert/ConfigAlertLineNotify.vue'; +import ConfigAlertMattermost from '@/components/config/alert/ConfigAlertMattermost.vue'; +import ConfigAlertMsTeams from '@/components/config/alert/ConfigAlertMsTeams.vue'; +import ConfigAlertPagerTree from '@/components/config/alert/ConfigAlertPagerTree.vue'; +import ConfigAlertRocketChat from '@/components/config/alert/ConfigAlertRocketChat.vue'; +import ConfigAlertServiceNow from '@/components/config/alert/ConfigAlertServiceNow.vue'; +import ConfigAlertSlack from '@/components/config/alert/ConfigAlertSlack.vue'; +import ConfigAlertStomp from '@/components/config/alert/ConfigAlertStomp.vue'; +import ConfigAlertTelegram from '@/components/config/alert/ConfigAlertTelegram.vue'; +import ConfigAlertTheHive from '@/components/config/alert/ConfigAlertTheHive.vue'; +import ConfigAlertTwilio from '@/components/config/alert/ConfigAlertTwilio.vue'; +import ConfigAlertVictorOps from '@/components/config/alert/ConfigAlertVictorOps.vue'; +import ConfigAlertZabbix from '@/components/config/alert/ConfigAlertZabbix.vue'; import ConfigKibanaDiscover from '@/components/config/ConfigKibanaDiscover.vue'; import ConfigTimeWindowFeature from '@/components/config/ConfigTimeWindowFeature.vue'; import ConfigOwner from '@/components/config/ConfigOwner.vue'; @@ -21,11 +47,39 @@ import ConfigPriority from '@/components/config/ConfigPriority.vue'; import ConfigDescription from '@/components/config/ConfigDescription.vue'; import ConfigSettings from '@/components/config/ConfigSettings.vue'; import ConfigCondition from '@/components/config/ConfigCondition.vue'; +import ConfigScanEntireTimeframe from '@/components/config/ConfigScanEntireTimeframe.vue'; +import ConfigLimitExcecution from '@/components/config/ConfigLimitExcecution.vue'; Vue.component('Bulb', Bulb); Vue.component('DateTime', DateTime); Vue.component('ConfigQuery', ConfigQuery); Vue.component('ConfigAlert', ConfigAlert); +Vue.component('ConfigAlertAlerta', ConfigAlertAlerta); +Vue.component('ConfigAlertAmazonSes', ConfigAlertAmazonSes); +Vue.component('ConfigAlertAmazonSns', ConfigAlertAmazonSns); +Vue.component('ConfigAlertChatwork', ConfigAlertChatwork); +Vue.component('ConfigAlertCommand', ConfigAlertCommand); +Vue.component('ConfigAlertDatadog', ConfigAlertDatadog); +Vue.component('ConfigAlertDiscord', ConfigAlertDiscord); +Vue.component('ConfigAlertEmail', ConfigAlertEmail); +Vue.component('ConfigAlertExotel', ConfigAlertExotel); +Vue.component('ConfigAlertGitter', ConfigAlertGitter); +Vue.component('ConfigAlertGoogleChat', ConfigAlertGoogleChat); +Vue.component('ConfigAlertHttpPost', ConfigAlertHttpPost); +Vue.component('ConfigAlertJira', ConfigAlertJira); +Vue.component('ConfigAlertLineNotify', ConfigAlertLineNotify); +Vue.component('ConfigAlertMattermost', ConfigAlertMattermost); +Vue.component('ConfigAlertMsTeams', ConfigAlertMsTeams); +Vue.component('ConfigAlertPagerTree', ConfigAlertPagerTree); +Vue.component('ConfigAlertRocketChat', ConfigAlertRocketChat); +Vue.component('ConfigAlertServiceNow', ConfigAlertServiceNow); +Vue.component('ConfigAlertSlack', ConfigAlertSlack); +Vue.component('ConfigAlertStomp', ConfigAlertStomp); +Vue.component('ConfigAlertTelegram', ConfigAlertTelegram); +Vue.component('ConfigAlertTheHive', ConfigAlertTheHive); +Vue.component('ConfigAlertTwilio', ConfigAlertTwilio); +Vue.component('ConfigAlertVictorOps', ConfigAlertVictorOps); +Vue.component('ConfigAlertZabbix', ConfigAlertZabbix); Vue.component('ConfigAggregation', ConfigAggregation); Vue.component('ConfigSettings', ConfigSettings); Vue.component('ConfigKibanaDiscover', ConfigKibanaDiscover); @@ -34,6 +88,8 @@ Vue.component('ConfigOwner', ConfigOwner); Vue.component('ConfigPriority', ConfigPriority); Vue.component('ConfigDescription', ConfigDescription); Vue.component('ConfigCondition', ConfigCondition); +Vue.component('ConfigScanEntireTimeframe', ConfigScanEntireTimeframe); +Vue.component('ConfigLimitExcecution', ConfigLimitExcecution); Vue.component('DefinitionTable', DefinitionTable); Vue.component('ElastalertTimePicker', ElastalertTimePicker); Vue.component('ESChart', ESChart); diff --git a/src/store/config/alert.js b/src/store/config/alert.js index 0d8ad200..2699f596 100644 --- a/src/store/config/alert.js +++ b/src/store/config/alert.js @@ -139,6 +139,9 @@ function initialState() { useOwner: false, configOwner: '', + /* scanEntireTimeframe */ + scanEntireTimeframe: false, + /* Jira */ jiraProject: '', jiraIssueType: '', @@ -1217,6 +1220,11 @@ export default { state.kibanaDiscoverColumns[index] = entry; }, + /* scan_entire_timeframe */ + UPDATE_SCAN_ENTIRE_TIMEFRAME(state, scanEntireTimeframe) { + state.scanEntireTimeframe = scanEntireTimeframe; + }, + UPDATE_REALERT(state, realert) { state.realert = realert; }, diff --git a/src/store/config/index.js b/src/store/config/index.js index 1326d30b..bd54d5ee 100644 --- a/src/store/config/index.js +++ b/src/store/config/index.js @@ -204,6 +204,9 @@ export default { commit('alert/UPDATE_KIBANA_DISCOVER_FROM_TIMEDELTA', config.kibana_discover_from_timedelta); commit('alert/UPDATE_KIBANA_DISCOVER_TO_TIMEDELTA', config.kibana_discover_to_timedelta); + /* scan_entire_timeframe */ + commit('alert/UPDATE_SCAN_ENTIRE_TIMEFRAME', config.scan_entire_timeframe); + /* Description */ commit('alert/UPDATE_DESCRIPTION', config.description); @@ -1723,6 +1726,17 @@ export default { return config; }, + // scan_entire_timeframe + scanEntireTimeframe(state) { + let config = {}; + + if (state.alert.scanEntireTimeframe) { + config.scan_entire_timeframe = state.alert.scanEntireTimeframe; + } + + return config; + }, + // Priority priority(state) { let config = {}; @@ -2396,6 +2410,8 @@ export default { config = { ...config, ...getters.owner }; + config = { ...config, ...getters.scanEntireTimeframe }; + // Sort the keys in the object so it appears alphabetically in the UI let conf = {};