Enable ELK alerts
To receive notifications from ELK, configure alerting:
On your main installation server, in the directory with the installation package, edit
config.yml.$ cd /opt/workfusion/wf_installer $ ./install.sh edit_config INSTALLATION_SERVERTo enable email and Slack notifications, set the
alerting_email_enabledandalerting_slack_enabledparameters toTrue, and change other parameters. All ELK watchers are already pre-configured.# Email alerts configuration alerting_email_enabled: False # Set to 'True' to enable notifications via email alerting_email_to: 'org.support.sre@example.local' # Specify the email address to which alerts will be sent alerting_email_from: 'alert@example.local' # Specify the email address from which alerts will be sent. This parameter is also a login name for an SMTP server alerting_email_account: 'standard' # A watcher provides three email profiles that control how MIME messages are structured: 'standard', 'outlook', or 'gmail'. These profiles accommodate differences in how various email systems interpret the MIME standard. If you are using Gmail or Outlook, we recommend using the corresponding profile. Use the "standard" profile if you have another email system. Supported values: 'standard', 'outlook', or 'gmail'. alerting_email_host: 'smtp.example.local' # Set an SMPT server, for example, smtp.gmail.com, smtp.office365.com, YOUR_CUSTOM_EXCHANGE_SERVER alerting_email_port: '587' # Set a port of your SMTP server alerting_email_pass: 'changeme' # Specify an SMTP password of the email account, from which alerting emails will be sent # Slack alerts configuration alerting_slack_enabled: False # Set to "True" to enable Slack notifications alerting_slack_hook: 'https://hooks.slack.com/services/xxx/xxx' # Specify a Slack webhook used for integration. A Slack admin configures this parameter for your Slack account before installation in https://my.slack.com/services/new/incoming-webhook. For more information, refer to https://www.elastic.co/guide/en/elasticsearch/reference/current/actions-slack.html alerting_slack_account: 'your-slack-account' # Enter an account name for the specified webhook URL in the Elasticsearch Keystore alerting_slack_channel: 'Workfusion-ALERTS' # Specify the Slack channel for alerting. You can enter an array of channels, for example: [ "#admins", "@chief-admin" ]To enable alerts, on the installation server, run the following commands:
$ ./install.sh alerting_enable elasticsearch -c local
$ ./install.sh alerting_enable kibana -c local
Prepare the environment variables:
$ export ANSIBLE_PRIVATE_KEY_FILE="</path_to_ssh_key>" # Path to SSH key for connection to all Linux server as WFUSER
$ export ANSIBLE_REMOTE_USER="WFUSER" # WFUSER provided in config.yml
$ export ANSIBLE_VAULT_PASS="<ansible_vault_password>" # Password for decryption of config.yml. If you don't set this variable, you'll be prompted for passwordRun the commands:
$ ./install.sh alerting_enable elasticsearch
$ ./install.sh alerting_enable kibana