Skip to content

Commit a401d13

Browse files
committed
[BuildImage] Prevent service restarts during installation of ubuntu-desktop, required by DCV, to avoid SSM agent connecgtivity issue.
In particular: * Add NEEDRESTART_MODE=l environment variable to suppress needrestart prompts during installation
1 parent 67bb15a commit a401d13

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

cookbooks/aws-parallelcluster-platform/resources/dcv/partial/_ubuntu_common.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ def pre_install
4545
code <<-PREREQ
4646
set -e
4747
DEBIAN_FRONTEND=noninteractive
48+
NEEDRESTART_MODE=l
4849
apt -y install whoopsie
4950
apt -y install ubuntu-desktop && apt -y install mesa-utils || (dpkg --configure -a && exit 1)
5051
apt -y purge ifupdown

cookbooks/aws-parallelcluster-platform/spec/unit/resources/dcv_spec.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -472,6 +472,7 @@ def self.nothing(chef_run)
472472
when 'ubuntu'
473473
is_expected.to periodic_apt_update('')
474474
is_expected.to run_bash('install pre-req').with_cwd(Chef::Config[:file_cache_path]).with_retries(10).with_retry_delay(5)
475+
.with_code(/NEEDRESTART_MODE=l/)
475476
.with_code(/apt -y install whoopsie/)
476477
.with_code(/apt -y install ubuntu-desktop && apt -y install mesa-utils || (dpkg --configure -a && exit 1)/)
477478
.with_code(/apt -y purge ifupdown/)

0 commit comments

Comments
 (0)