diff options
author | Christopher Baines <mail@cbaines.net> | 2018-07-01 09:01:53 +0100 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2018-07-01 09:01:53 +0100 |
commit | a25950c4683036315632d44e3ef3d3d2d1da7a3d (patch) | |
tree | d95765aeafa060237b93a229545a18a818385d05 | |
parent | 53341fafbede0ea3a1dfe0f53659b8f00aa3f723 (diff) | |
download | govuk-mini-environment-admin-a25950c4683036315632d44e3ef3d3d2d1da7a3d.tar govuk-mini-environment-admin-a25950c4683036315632d44e3ef3d3d2d1da7a3d.tar.gz |
Actually include the data snapshot when building
-rw-r--r-- | app/services/govuk_guix/build_mini_environment.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/app/services/govuk_guix/build_mini_environment.rb b/app/services/govuk_guix/build_mini_environment.rb index 8e2d912..01920eb 100644 --- a/app/services/govuk_guix/build_mini_environment.rb +++ b/app/services/govuk_guix/build_mini_environment.rb @@ -51,12 +51,21 @@ module GovukGuix::BuildMiniEnvironment ) end + data_snapshot_arguments = {} + + if mini_environment.data_snapshot + data_snapshot_arguments[:data_snapshot] = + mini_environment.data_snapshot.store_path + end + output = run_command( "#{mini_environment.govuk_guix_revision.store_path}/bin/govuk", 'system', 'build', *hash_to_arguments( - DEFAULT_ARGUMENTS.merge(options[:arguments]) + DEFAULT_ARGUMENTS + .merge(options[:arguments]) + .merge(data_snapshot_arguments) ), *signon_user_arguments(mini_environment.signon_users), *options[:services], |