diff options
author | Philipp Herzog | 2022-11-18 19:46:37 +0100 |
---|---|---|
committer | GitHub | 2022-11-18 19:46:37 +0100 |
commit | 2a3c5f70eee04a465aa534d8bd4fcc9bb3c4a8ce (patch) | |
tree | 105f43d6190a650b151be3826a101e289b730703 /src/cli.rs | |
parent | be40823735bbdc40c1f6b7725c8b74d5a85d8023 (diff) | |
parent | d0c86650424ae60209767a90d5c93012c95b0fec (diff) |
Merge pull request #175 from serokell/philtaken/remote-building
Add option to build on the target host
Diffstat (limited to 'src/cli.rs')
-rw-r--r-- | src/cli.rs | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -56,6 +56,10 @@ pub struct Opts { #[clap(short, long)] skip_checks: bool, + /// Build on remote host + #[clap(long)] + remote_build: bool, + /// Override the SSH user with the given value #[clap(long)] ssh_user: Option<String>, @@ -138,9 +142,7 @@ async fn check_deployment( .arg(format!("let r = import {}/.; x = (if builtins.isFunction r then (r {{}}) else r); in if x ? checks then x.checks.${{builtins.currentSystem}} else {{}}", repo)); } - for extra_arg in extra_build_args { - check_command.arg(extra_arg); - } + check_command.args(extra_build_args); let check_status = check_command.status().await?; @@ -239,9 +241,7 @@ async fn get_deployment_data( .arg(format!("let r = import {}/.; in if builtins.isFunction r then (r {{}}).deploy else r.deploy", flake.repo)) }; - for extra_arg in extra_build_args { - c.arg(extra_arg); - } + c.args(extra_build_args); let build_child = c .stdout(Stdio::piped()) @@ -640,6 +640,7 @@ pub async fn run(args: Option<&ArgMatches>) -> Result<(), RunError> { temp_path: opts.temp_path, confirm_timeout: opts.confirm_timeout, dry_activate: opts.dry_activate, + remote_build: opts.remote_build, sudo: opts.sudo, }; |