first commit
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
#!/bin/bash
|
||||
cd /root/xplayer-ota
|
||||
git restore .
|
||||
git pull
|
||||
|
||||
# Download and extract files before running ansible-playbook
|
||||
if [ -f "files_download.txt" ]; then
|
||||
echo "Downloading files from files_download.txt..."
|
||||
while IFS= read -r url; do
|
||||
if [ -n "$url" ]; then
|
||||
filename=$(basename "$url")
|
||||
echo "Downloading $filename..."
|
||||
wget -O "$filename" "$url"
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "Extracting $filename..."
|
||||
tar -xJf "$filename"
|
||||
rm -f "$filename"
|
||||
else
|
||||
echo "Failed to download $url"
|
||||
fi
|
||||
fi
|
||||
done < files_download.txt
|
||||
fi
|
||||
|
||||
ansible-playbook playbooks/site.yml
|
||||
Reference in New Issue
Block a user