mirror of
https://github.com/FAUSheppy/config
synced 2025-12-06 15:11:35 +01:00
cip
This commit is contained in:
@@ -46,6 +46,12 @@ def vpn_status():
|
|||||||
with open(vpn_path,'w+') as g:
|
with open(vpn_path,'w+') as g:
|
||||||
g.write(out_vpn)
|
g.write(out_vpn)
|
||||||
|
|
||||||
|
def cip_logins():
|
||||||
|
l=hl_utils.shexec("wget -q -O- --user cip --password $(cat $HOME/.config/password.cip) 'https://atlantishq.de/cipactive/active_logins'")
|
||||||
|
if len(l) > 5:
|
||||||
|
return hl_utils.color_panel("CIP Logins: "+str(len(l)),RED)
|
||||||
|
color = hl_utils.get_color(
|
||||||
|
|
||||||
def battery():
|
def battery():
|
||||||
try:
|
try:
|
||||||
bat = shexec("acpi -b")
|
bat = shexec("acpi -b")
|
||||||
@@ -97,7 +103,6 @@ def trace_login():
|
|||||||
f.write(tmp)
|
f.write(tmp)
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
#print('"'+sys.argv[-1]+'"')
|
|
||||||
while(True):
|
while(True):
|
||||||
vpn_status()
|
vpn_status()
|
||||||
pr_acct_status()
|
pr_acct_status()
|
||||||
|
|||||||
8
zshrc
8
zshrc
@@ -300,12 +300,12 @@ alias ssh="ssh_func"
|
|||||||
### EXPERIMENTAL ###
|
### EXPERIMENTAL ###
|
||||||
## kill all cip sessions except this pc ##
|
## kill all cip sessions except this pc ##
|
||||||
genocide(){
|
genocide(){
|
||||||
while IFS='' read -r line || [[ -n "$line" ]]; do
|
TMP=$(wget -q -O- --user cip --password $(cat $HOME/.config/password.cip) "https://atlantishq.de/cipactive/active_logins")
|
||||||
|
echo $TMP | while read line; do
|
||||||
if [[ $line != $HOST ]]; then
|
if [[ $line != $HOST ]]; then
|
||||||
ssh -q $line -t "pkill -u ik15ydit"
|
ssh -n -q $line -t "pkill -u ik15ydit"
|
||||||
fi
|
fi
|
||||||
done < "$HOME/.config/cip_logins"
|
done
|
||||||
#truncate -s 0 ~/.config/cip_logins
|
|
||||||
}
|
}
|
||||||
export genocide
|
export genocide
|
||||||
alias insurgency_status="ssh insurgency@atlantishq.de -t /usr/local/bin/insurgency_rcon status"
|
alias insurgency_status="ssh insurgency@atlantishq.de -t /usr/local/bin/insurgency_rcon status"
|
||||||
|
|||||||
Reference in New Issue
Block a user