← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1954842] [NEW] ubuntu-advantage enable fips will fail due to missing --assume-yes

 

Public bug reported:

cloud-provider: AWS
cloud-init configuration (relevant section):

ubuntu-advantage:
  token: <ua_contract_token>
  enable:
  - fips

(no reports attached, as bug is viewable in the code, however I can
reproduce if you'd like)

ubuntu-advantage (ua) calls often have prompts. the ubuntu_advantage
directive runs without the `--assume-yes` flag from ua

    for service in enable:
        try:
            cmd = ['ua', 'enable', service]
            subp.subp(cmd, capture=True)
        except subp.ProcessExecutionError as e:
            enable_errors.append((service, e))


https://github.com/canonical/cloud-init/blob/bedac77e9348e7a54c0ec364fb61df90cd893972/cloudinit/config/cc_ubuntu_advantage.py#L124

This will not work with FIPS, as running `ua enable fips` without
`--assume-yes` will result in prompts.

I propose having `ua enable --assume-yes $service` be the default call
in cloud-init

** Affects: cloud-init
     Importance: Medium
         Status: Triaged

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/1954842

Title:
  ubuntu-advantage enable fips will fail due to missing --assume-yes

Status in cloud-init:
  Triaged

Bug description:
  cloud-provider: AWS
  cloud-init configuration (relevant section):

  ubuntu-advantage:
    token: <ua_contract_token>
    enable:
    - fips

  (no reports attached, as bug is viewable in the code, however I can
  reproduce if you'd like)

  ubuntu-advantage (ua) calls often have prompts. the ubuntu_advantage
  directive runs without the `--assume-yes` flag from ua

      for service in enable:
          try:
              cmd = ['ua', 'enable', service]
              subp.subp(cmd, capture=True)
          except subp.ProcessExecutionError as e:
              enable_errors.append((service, e))

  
  https://github.com/canonical/cloud-init/blob/bedac77e9348e7a54c0ec364fb61df90cd893972/cloudinit/config/cc_ubuntu_advantage.py#L124

  This will not work with FIPS, as running `ua enable fips` without
  `--assume-yes` will result in prompts.

  I propose having `ua enable --assume-yes $service` be the default call
  in cloud-init

To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1954842/+subscriptions



Follow ups