Add .editorconfig and correct indentation for many seqs

This commit is contained in:
2022-03-14 21:27:29 +01:00
parent bb8b54597a
commit 71612aef94
34 changed files with 178 additions and 164 deletions

View File

@@ -122,10 +122,10 @@ step_20() {
exe chmod +x "$rpiExtendLoc"
addConf -a "extend raspberry /etc/snmp/raspberry.sh" "$toolConfig"
# VCHI initialization failed fix
exe usermod -aG video ${toolSysUser}
addConf -s "$rpiSudoersContent" "$rpiSudoersLoc"
exe service snmpd restart
@@ -141,7 +141,7 @@ step_22() {
if [ "$?" != "0" ]; then
return 1
fi
exe wget https://raw.githubusercontent.com/librenms/librenms-agent/master/snmp/osupdate -O "${osUpdateExtendLoc}"
endReturn -o $? "Download failed"
exe chmod +x "$osUpdateExtendLoc"
@@ -383,11 +383,11 @@ step_40() {
if [ $? -ne 0 ]; then
return 0
fi
exe wget https://raw.githubusercontent.com/librenms/librenms-agent/master/snmp/distro -O "${distroExtendLoc}"
endReturn -o $? "Download distro detection script failed"
exe chmod +x "$distroExtendLoc"
echoseq " [I] Create distro extend"
addConf -a "extend distro ${distroExtendLoc}" "$toolConfig"
@@ -415,13 +415,13 @@ step_42() {
exe wget $locExtUrl -O "${locExtLoc}"
endReturn -o $? "Download $locExtName script failed"
exe chmod +x "$locExtLoc"
echoseq " [I] Create extend for $locExtName"
addConf -a "extend $locExtName ${locExtLoc}" "$toolConfig"
echoseq " [I] Create config for $locExtName"
addConf -s "$dhcpExtendConfig" "$dhcpExtendConfigLoc"
echo " [W] Adapt config $dhcpExtendConfigLoc manually and restart snmpd"
}
dhcpExtendConfigLoc="${toolConfigLoc}/dhcp.json"
@@ -530,7 +530,7 @@ checkExtend() {
if [ $? -eq 0 ] && [ $DRY -eq 0 ] ; then
return 1
fi
return 0
}