I am trying to test a bash script on the cloud, but when I submit it, it repeatedly switch between SCHEDULE and QUEUE and never ran. Here is the bash script that I am trying to run:
#!/bin/bash
source /opt/conda/etc/profile.d/conda.sh
conda activate WaifuDiffusion
export FOLDER=/home/kannachan/SeaSalt-Downloader
python $FOLDER/main.py -u "https://danbooru.donmai.us/posts?tags=mika_pikazo" \
--scraper danbooru \
--filter tag_filter animated video \
--saver folder mika_pikazo
I config my job as follows:
{
"taskGroups": [
{
"taskSpec": {
"runnables": [
{
"script": {
"text": "#!/bin.bash\n bash ../run.sh"
}
}
],
"computeResource": {
"cpuMilli": 2000,
"memoryMib": 16
},
"maxRetryCount": 2,
"maxRunDuration": "3600s"
},
"taskCount": 4,
"parallelism": 2
}
],
"allocationPolicy": {
"instances": [
{
"policy": { "machineType": "g2-standard-8" }
}
]
},
"labels": {
"department": "ai",
"env": "web-scrapper"
},
"logsPolicy": {
"destination": "CLOUD_LOGGING"
}
}
Both run.sh and config.json is in the same directory. I ran:
gcloud batch jobs submit batch-job-1 --location us-central1 --config config.json
gcloud batch jobs submit batch-job-1 --location us-central1 --config config.json
Hi @ModernNoob,
Welcome to the Google Cloud Community!
You can try the following troubleshooting options:
Let me know if it helped, thanks!
User | Count |
---|---|
15 | |
1 | |
1 | |
1 | |
1 |