feat: with update deployment
Some checks failed
continuous-integration/drone/push Build is failing

Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
Kasper Juul Hermansen 2023-11-27 21:34:23 +01:00
parent a900ebae54
commit b879da4d2f
Signed by: kjuulh
GPG Key ID: 57B6E1465221F912

View File

@ -339,6 +339,28 @@ impl MainAction for RustService {
)) ))
.await?; .await?;
let update_deployments_docker_image =
"docker.io/kasperhermansen/update-deployment:1690401410";
self.client
.container()
.from(update_deployments_docker_image)
.with_env_variable("GIT_USERNAME", "kjuulh")
.with_env_variable("GIT_PASSWORD", std::env::var("GIT_PASSWORD").unwrap())
.with_exec(vec![
"update-deployment",
"--repo",
&format!(
"https://git.front.kjuulh.io/kjuulh/{}-deployment.git",
self.bin_name
),
"--service",
&self.bin_name,
"--image",
&format!("kasperhermansen/{}:main-{}", self.bin_name, timestamp),
])
.exit_code()
.await?;
Ok(()) Ok(())
} }
} }