File size: 733 Bytes
14bd491
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
# List of IP addresses
hosts=("10.100.193.14"
    "10.100.193.16"
    "10.100.193.29"
    "10.100.193.37"
    "10.100.193.41"
    "10.100.193.75"
    "10.100.193.84"
    "10.100.193.96"
    "10.100.193.97"
    "10.100.193.137"
    "10.100.193.158"
    "10.100.193.164"
    "10.100.193.172"
    "10.100.193.181"
    "10.100.193.192"
    "10.100.193.198"
    "10.100.193.232"
    "10.100.193.233"
    "10.100.193.253"
    )

# Read the contents of setup_env_huggingface.sh into a variable
script_content=$(<setup_env_huggingface.sh)

for host in "${hosts[@]}"; do
    # Execute the script content remotely using a heredoc
    ssh -T jump-eu.tiktok-row.org << EOF
    ssh root@$host 'bash -s' <<< "$script_content"
EOF
done