From 89f23d284796f51a0386c7127ee56be231189edd Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sun, 3 Jun 2018 13:09:25 +0100 Subject: Use the run_remotely_on_host option in BuildJob --- app/jobs/govuk_guix/build_job.rb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'app/jobs') diff --git a/app/jobs/govuk_guix/build_job.rb b/app/jobs/govuk_guix/build_job.rb index c4da654..94acd70 100644 --- a/app/jobs/govuk_guix/build_job.rb +++ b/app/jobs/govuk_guix/build_job.rb @@ -37,8 +37,6 @@ class GovukGuix::BuildJob < GovukGuix::Job remote_host = options[:run_remotely_on_host] if remote_host - ssh_command = ['ssh', remote_host] - # Copy the revision to the remote host, to ensure it's available # there run_command( @@ -47,12 +45,9 @@ class GovukGuix::BuildJob < GovukGuix::Job "--to=#{remote_host}", mini_environment.govuk_guix_revision.store_path ) - else - ssh_command = [] end output = run_command( - *ssh_command, "#{mini_environment.govuk_guix_revision.store_path}/bin/govuk", 'system', 'build', @@ -60,7 +55,8 @@ class GovukGuix::BuildJob < GovukGuix::Job DEFAULT_ARGUMENTS.merge(options[:arguments]) ), *signon_user_arguments(mini_environment.signon_users), - *options[:services] + *options[:services], + run_remotely_on_host: remote_host ) build_output = output.last.strip -- cgit v1.2.3