Compare commits

...

3 Commits

Author SHA1 Message Date
6707e7e403 fix failed pre-commit checks
All checks were successful
continuous-integration/drone/push Build is passing
2024-02-08 18:02:09 +01:00
9971b46e9e Merge branch 'main' of gitea:jheuel/zoidberg
Some checks failed
continuous-integration/drone/push Build is failing
2024-02-08 17:57:16 +01:00
302e47c342 . 2024-02-08 17:56:32 +01:00
3 changed files with 12 additions and 5 deletions

View File

@@ -6,4 +6,3 @@
# sleep 10
/home/home4/institut_1b/jheuel/repositories/zoidberg/target/release/zoidberg_client

View File

@@ -4,12 +4,21 @@ import sys
import requests
from os import environ
from snakemake.utils import read_job_properties
jobscript = sys.argv[1]
job_properties = read_job_properties(jobscript)
payload = {
"cmd": jobscript
}
payload["threads"] = job_properties.get("threads", 1)
resp = requests.post(
"http://localhost:8080/submit",
json=[
{"cmd": jobscript},
payload,
],
headers={"cookie": environ["ZOIDBERG_SECRET"]},
)

View File

@@ -155,9 +155,8 @@ async fn main() -> Result<(), Box<dyn Error>> {
std::process::exit(1);
});
let server = std::env::var("ZOIDBERG_SERVER").unwrap_or_else(|_| {
String::from(matches.value_of("server").unwrap())
});
let server = std::env::var("ZOIDBERG_SERVER")
.unwrap_or_else(|_| String::from(matches.value_of("server").unwrap()));
let client = Arc::new(
Worker::new(&server, &secret, threads)