Skip to content
This repository was archived by the owner on Jun 24, 2022. It is now read-only.

Commit 1308f8d

Browse files
authored
Cleaned up, clarified, and updated readme.
1 parent ac0f5ab commit 1308f8d

File tree

1 file changed

+39
-61
lines changed

1 file changed

+39
-61
lines changed

README.md

Lines changed: 39 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -9,87 +9,65 @@ Sends notifications from Veeam Backup & Restore to Slack
99
---
1010
## [Discord Setup](https://blog.tiga.tech/veeam-b-r-notifications-in-discord/)
1111

12-
## Slack Setup
12+
## Slack setup
13+
14+
#### 1. Create destination directory
15+
16+
We'll be using PowerShell to get started with this.
1317

1418
Make a scripts directory: `C:\VeeamScripts`
1519

16-
```powershell
17-
# To make the directory run the following command in PowerShell
20+
```PowerShell
1821
New-Item C:\VeeamScripts PowerShell -type directory
1922
```
2023

21-
#### Get code
22-
23-
Then clone this repository:
24+
#### 2. Download the project
2425

25-
```shell
26-
cd C:\VeeamScripts
27-
git clone https://github.com/tigattack/VeeamSlackNotifications.git
28-
cd VeeamSlackNotifications
29-
git checkout master
30-
```
31-
32-
Or without git:
26+
There may be later releases so [take a look](https://github.com/tigattack/VeeamSlackNotifications/releases) and replace the version number in the commands below with the latest if applicable.
3327

34-
Download release, there may be later releases take a look and replace the version number with newer release numbers.
35-
Unzip the archive and make sure the folder is called: `VeeamSlackNotifications`
36-
```powershell
37-
Invoke-WebRequest -Uri https://github.com/tigattack/VeeamSlackNotifications/archive/2.1.zip -OutFile C:\VeeamScripts\VeeamSlackNotifications-v1.0.zip
28+
Download the archive and rename it to something recognisable.
29+
```PowerShell
30+
Invoke-WebRequest -Uri https://github.com/tigattack/VeeamSlackNotifications/archive/2.4.zip -OutFile C:\VeeamScripts\VeeamSlackNotifications-2.4.zip
3831
```
39-
You may recieve an SSL error as winhttp uses TLS1 by default in some case (depends on a few things), which GitHub appears to no longer accept. IF you recieve this error, run the following and re-issue the above command.
40-
```powershell
32+
You may recieve an SSL error as in some cases winhttp uses TLS1 by default (depends on a few things), and GitHub appears to no longer accept TLS1. If you receive this error, run the following command and then re-issue the above command.
33+
```PowerShell
4134
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
4235
```
4336

44-
#### Extract and clean up
45-
```shell
46-
Expand-Archive C:\VeeamScripts\VeeamSlackNotifications-v2.2.zip -DestinationPath C:\VeeamScripts
47-
Ren C:\VeeamScripts\VeeamSlackNotifications-2.2 C:\VeeamScripts\VeeamSlackNotifications
48-
rm C:\VeeamScripts\VeeamSlackNotifications-v2.2.zip
37+
#### 3. Extract and clean up
38+
```PowerShell
39+
Expand-Archive C:\VeeamScripts\VeeamSlackNotifications-2.4.zip -DestinationPath C:\VeeamScripts
40+
Ren C:\VeeamScripts\VeeamSlackNotifications-2.4 C:\VeeamScripts\VeeamSlackNotifications
41+
rm C:\VeeamScripts\VeeamSlackNotifications-v2.4.zip
4942
```
5043

51-
#### Prepare for use
52-
Make a new config file
53-
```shell
54-
cp C:\VeeamScripts\VeeamSlackNotifications\config\vsn.example.json C:\VeeamScripts\VeeamSlackNotifications\config\vsn.json
44+
#### 4. Prepare for use
45+
Edit your config file. You must replace the webhook field with your own webhook.
46+
```PowerShell
47+
notepad.exe C:\VeeamScripts\VeeamSlackNotifications\config\conf.json
5548
```
56-
Edit your config file. You must replace the webhook field with your own Slack url.
57-
```shell
58-
notepad.exe C:\VeeamScripts\VeeamSlackNotifications\config\vsn.json
49+
You may also need to set your PowerShell execution policy to Unrestricted.
50+
```PowerShell
51+
Set-ExecutionPolicy Unrestricted
5952
```
60-
Unblock the script files. Windows often blocks execution of downloaded scripts.
61-
```powershell
53+
If you don't want to do that, replace the script path in section 5 below with the following
54+
```PowerShell
55+
Powershell.exe -ExecutionPolicy Bypass -File C:\VeeamScripts\VeeamSlackNotifications\SlackNotificationBootstrap.ps1
56+
```
57+
58+
Unblock the script files if you're still having issues after setting the PowerShell execution policy. The reason you may need to do this is Windows often blocks execution of downloaded scripts.
59+
```PowerShell
6260
Unblock-File C:\VeeamScripts\VeeamSlackNotifications\SlackNotificationBootstrap.ps1
6361
Unblock-File C:\VeeamScripts\VeeamSlackNotifications\SlackVeeamAlertSender.ps1
6462
Unblock-File C:\VeeamScripts\VeeamSlackNotifications\Helpers\Helpers.psm1
6563
```
66-
You may also need to set your PowerShell execution policy to Unrestricted if you're still having issues after unblocking the scripts.
67-
```powershell
68-
Set-ExecutionPolicy Unrestricted
69-
```
70-
71-
Finally, open Veeam and configure your jobs. Edit them and click on the <img src="asset/img/screens/sh-3.png" height="20"> button.
72-
73-
Navigate to the "Scripts" tab and paste the following line the script that runs after the job is completed:
74-
75-
```shell
76-
Powershell.exe -File C:\VeeamScripts\VeeamSlackNotifications\SlackNotificationBootstrap.ps1
77-
```
7864

65+
#### 5. Configure in Veeam
66+
Repeat this for each job that you want to be reported into Slack.
67+
* Right click the job and click "Edit".
68+
* Go to the "Storage" section and click on the <img src="asset/img/screens/sh-3.png" height="20"> button.
69+
* Go to the "Scripts" tab and configure as shown below.
7970
![screen](asset/img/screens/sh-1.png)
80-
81-
---
82-
83-
## Example Configuration:
84-
85-
Below is an example configuration file.
86-
87-
```shell
88-
{
89-
"webhook": "https://...",
90-
"channel": "#veeam",
91-
"service_name": "Veeam B&R",
92-
"icon_url": "https://raw.githubusercontent.com/tigattack/VeeamSlackNotifications/master/asset/img/icon/VeeamB%26R.png",
93-
"debug_log": false
94-
}
71+
```PowerShell
72+
Powershell.exe -File C:\VeeamScripts\VeeamSlackNotifications\SlackNotificationBootstrap.ps1
9573
```

0 commit comments

Comments
 (0)