-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #377 from sexibytes/develop
Merge before release 0.99j - St. Olga
- Loading branch information
Showing
63 changed files
with
4,874 additions
and
549 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
37 1 * * * root /usr/bin/pwsh -NonInteractive -NoProfile -f /opt/sexigraf/xMotionGarbageCollector.ps1 >/dev/null 2>&1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
apiVersion: 1 | ||
|
||
providers: | ||
# <string> an unique provider name | ||
- name: 'Veeam' | ||
# <int> org id. will default to orgId 1 if not specified | ||
orgId: 1 | ||
# <string, required> name of the dashboard folder. Required | ||
folder: 'Veeam Backup & Replication' | ||
# <string> folder UID. will be automatically generated if not specified | ||
# CRC32 of name | ||
folderUid: '30fb6004' | ||
# <string, required> provider type. Required | ||
type: file | ||
# <bool> disable dashboard deletion | ||
disableDeletion: false | ||
# <bool> enable dashboard editing | ||
editable: true | ||
# <int> how often Grafana will scan for changed dashboards | ||
updateIntervalSeconds: 10 | ||
# <bool> allow updating provisioned dashboards from the UI | ||
allowUiUpdates: false | ||
options: | ||
# <string, required> path to dashboard files on disk. Required | ||
path: /var/lib/grafana/dashboards/Veeam |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0.99i "Victory Mine" | ||
0.99j "St. Olga" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/usr/bin/pwsh -NonInteractive -NoProfile -Command | ||
# | ||
param([Parameter (Mandatory=$true)] [string] $server, [Parameter (Mandatory=$true)] [string] $username, [Parameter (Mandatory=$true)] [string] $password) | ||
|
||
# https://communities.vmware.com/t5/VMware-PowerCLI-Discussions/PowerCLI-on-Debian-Stretch-The-type-initializer-for-VMware/m-p/451739#M10646 | ||
Set-Content -Path Env:HOME -Value '/tmp' | ||
|
||
if (!$(Test-Connection -TargetName $server -TcpPort 9419 -TimeoutSeconds 2)) { | ||
Write-Host "$server is not answering at TCP:9419 check if VeeamBackupRESTSvc is running" | ||
exit 1 | ||
} | ||
|
||
try { | ||
$VbrHeaders = @{"accept" = "application/json";"x-api-version" = "1.0-rev1"} | ||
$VbrBody = @{grant_type = "password";username = $username;password = $password;refresh_token = "";code = "";use_short_term_refresh = ""} | ||
$VbrConnect = Invoke-RestMethod -SkipHttpErrorCheck -SkipCertificateCheck -Method POST -Uri $("https://" + $server + ":9419/api/oauth2/token") -Headers $VbrHeaders -ContentType "application/x-www-form-urlencoded" -Body $VbrBody | ||
if ($VbrConnect.access_token) { | ||
$SessionSecretName = "vbr_" + $server.Replace(".","_") + ".key" | ||
$SessionRefresh = "vbr_" + $server.Replace(".","_") + ".dat" | ||
$VbrConnect.access_token | Out-File -FilePath /tmp/$SessionSecretName | ||
$VbrConnect.refresh_token | Out-File -FilePath /tmp/$SessionRefresh | ||
Write-Host "Connected to $server" | ||
} else { | ||
Write-Host "Connection to $server failed!" | ||
exit 1 | ||
} | ||
} catch { | ||
# Invoke-RestMethod: Unable to read data from the transport connection: Connection reset by peer. | ||
# https://helpcenter.veeam.com/docs/backup/vbr_rest/tls_certificate.html | ||
Write-Host "$($Error[0])" | ||
exit 1 | ||
} |
Oops, something went wrong.