This commit is contained in:
2024-11-09 19:00:37 -06:00
parent 1445da20f1
commit f5aa20f6b0
24 changed files with 29 additions and 29 deletions

View File

@@ -1,6 +1,6 @@
#!/usr/bin/env bash #!/usr/bin/env bash
VERS='2.7.122-11092024' VERS='2.7.122b-11092024'
noheader=' update service dailytemp confsync -r -report test ' noheader=' update service dailytemp confsync -r -report test '
@@ -26,7 +26,7 @@ PW_LOGPOWER=${PW_LOGFOLDER}/log-power
M_SRVCOPT=(start stop restart reload enable disable) M_SRVCOPT=(start stop restart reload enable disable)
source ${PW_FOLDER}/settings.conf source ${PW_FOLDER}/conf/settings.conf
EMAIL_NOTICE=${PW_EMAIL_NOTICE} EMAIL_NOTICE=${PW_EMAIL_NOTICE}
PUSHOVER_APP_TOKEN=${PW_PUSHOVER_APP_TOKEN} PUSHOVER_APP_TOKEN=${PW_PUSHOVER_APP_TOKEN}
@@ -57,7 +57,7 @@ PW_ESXI_FANSPEEDCONTROLHOSTS=(${PW_ESXI_FANSPEEDCONTROL_HOSTS})
[ "${PW_TEMPIND_RANGE}" != "" ] && PW_TEMPIND_RANGE=(${PW_TEMPIND_RANGE}) [ "${PW_TEMPIND_RANGE}" != "" ] && PW_TEMPIND_RANGE=(${PW_TEMPIND_RANGE})
unset IFS unset IFS
if [ -f ${PW_FOLDER}/settings.local.conf ]; then if [ -f ${PW_FOLDER}/conf/settings.local.conf ]; then
declare -A PW_POWERWALL_SERVICES declare -A PW_POWERWALL_SERVICES
declare -A PW_THRESHOLDS declare -A PW_THRESHOLDS
declare -A PW_SENSOR_TYPE declare -A PW_SENSOR_TYPE
@@ -78,7 +78,7 @@ if [ -f ${PW_FOLDER}/settings.local.conf ]; then
declare -A PW_MISCSENSOR_DESC declare -A PW_MISCSENSOR_DESC
declare -A PW_DESC_TEMP declare -A PW_DESC_TEMP
source ${PW_FOLDER}/settings.local.conf source ${PW_FOLDER}/conf/settings.local.conf
[ "${PW_TEMPIND_DIFF}" == "" ] && PW_TEMPIND_DIFF=1 [ "${PW_TEMPIND_DIFF}" == "" ] && PW_TEMPIND_DIFF=1

View File

@@ -1,6 +1,6 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -2,7 +2,7 @@
### NOT WORKING ### ### NOT WORKING ###
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Write-Progress -Activity "Connecting to vCenter [$VCENTERHOST] ..." -PercentComplete 20 Write-Progress -Activity "Connecting to vCenter [$VCENTERHOST] ..." -PercentComplete 20

View File

@@ -1,6 +1,6 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Force -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null Connect-VIServer -Force -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Force -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null Connect-VIServer -Force -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
Set-PowerCLIConfiguration -InvalidCertificateAction Ignore -Confirm:$false | Out-Null Set-PowerCLIConfiguration -InvalidCertificateAction Ignore -Confirm:$false | Out-Null
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Force -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null Connect-VIServer -Force -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Write-Progress -Activity "Connecting to vCenter [$VCENTERHOST] ..." -PercentComplete 20 Write-Progress -Activity "Connecting to vCenter [$VCENTERHOST] ..." -PercentComplete 20

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
# Set-PowerCLIConfiguration -InvalidCertificateAction Ignore -Confirm:$false | Out-Null # Set-PowerCLIConfiguration -InvalidCertificateAction Ignore -Confirm:$false | Out-Null
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
# Set-PowerCLIConfiguration -InvalidCertificateAction Ignore -Confirm:$false | Out-Null # Set-PowerCLIConfiguration -InvalidCertificateAction Ignore -Confirm:$false | Out-Null

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh #!/usr/bin/env pwsh
. /opt/idssys/powerwall/settings.ps1 . /opt/idssys/powerwall/conf/settings.ps1
Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null

View File

@@ -16,7 +16,7 @@ PWO_START(){
startup=true startup=true
while true; do while true; do
. /opt/idssys/powerwall/settings.conf . /opt/idssys/powerwall/conf/settings.conf
PW_OFFSITEHOSTS=$(echo ${PW_OFFSITE_HOSTS} | tr ',' ' ') PW_OFFSITEHOSTS=$(echo ${PW_OFFSITE_HOSTS} | tr ',' ' ')
# TEST=true # TEST=true
# TEST=full # TEST=full

View File

@@ -759,11 +759,11 @@ GET_SNAPSHOTS(){
} }
CONFSYNC(){ CONFSYNC(){
[ "${PW_OFFSITE_MONITOR}" != "" ] && rsync -az --timeout=3 ${PW_FOLDER}/settings.conf root@${PW_OFFSITE_MONITOR}:${PW_FOLDER}/ & >/dev/null 2>&1 [ "${PW_OFFSITE_MONITOR}" != "" ] && rsync -az --timeout=3 ${PW_FOLDER}/conf/settings.conf root@${PW_OFFSITE_MONITOR}:${PW_FOLDER}/ & >/dev/null 2>&1
if [ -f /opt/idssys/nodemgmt/conf/defaults.local.inc ]; then if [ -f /opt/idssys/nodemgmt/conf/defaults.local.inc ]; then
source /opt/idssys/nodemgmt/defaults.inc source /opt/idssys/nodemgmt/defaults.inc
rsync -az --timeout=3 ${PW_FOLDER}/settings.* root@${NM_NODEMANAGER}:/opt/idssys/nodemgmt/conf/powerwall.settings.* & >/dev/null 2>&1 rsync -az --timeout=3 ${PW_FOLDER}/conf/* root@${NM_NODEMANAGER}:/opt/idssys/nodemgmt/conf/powerwall/ & >/dev/null 2>&1
# rsync -az --timeout=3 ${PW_FOLDER}/settings.ps1 root@${NM_NODEMANAGER}:/opt/idssys/nodemgmt/conf/powerwall.settings.ps1 & >/dev/null 2>&1 # rsync -az --timeout=3 ${PW_FOLDER}/conf/settings.ps1 root@${NM_NODEMANAGER}:/opt/idssys/nodemgmt/conf/powerwall.settings.ps1 & >/dev/null 2>&1
fi fi
} }