[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-10 Thread Launchpad Bug Tracker
This bug was fixed in the package base-files - 9.4ubuntu4.11

---
base-files (9.4ubuntu4.11) xenial; urgency=medium

  * update-motd.d/50-motd-news: add cloud_id to user-agent string
(LP: #1840946)
  * d/postinst.in, d/postrm: add missing dh_systemd_enable pieces. This
completes the fix for LP #1637800
  * d/postinst.in: do not start the motd-news.service, as it won't be
in an enabled state anyway, and the timer will run it when needed. This
addresses the motd-news.service bit in comment #19 of #1637800.

base-files (9.4ubuntu4.10) xenial; urgency=medium

  * Fix syntax error in new base-files postinst code.  LP: #1836236.

base-files (9.4ubuntu4.9) xenial; urgency=medium

  * Backport /etc/update-motd.d/50-motd-news, along with the systemd units
that are used to keep the local cache file up-to-date.  LP: #1637800

 -- Andreas Hasenack   Mon, 30 Sep 2019 10:31:01
-0300

** Changed in: base-files (Ubuntu Xenial)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-10 Thread Launchpad Bug Tracker
This bug was fixed in the package base-files - 10.1ubuntu2.7

---
base-files (10.1ubuntu2.7) bionic; urgency=medium

  * update-motd.d/50-motd-news: add cloud_id to user-agent string
(LP: #1840946)

 -- Andreas Hasenack   Fri, 27 Sep 2019 15:24:34
-0300

** Changed in: base-files (Ubuntu Bionic)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-10 Thread Launchpad Bug Tracker
This bug was fixed in the package base-files - 10.1ubuntu9.2

---
base-files (10.1ubuntu9.2) disco; urgency=medium

  * update-motd.d/50-motd-news: add cloud_id to user-agent string
(LP: #1840946)

 -- Andreas Hasenack   Fri, 27 Sep 2019 15:23:40
-0300

** Changed in: base-files (Ubuntu Disco)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-04 Thread Andreas Hasenack
Bionic verification: passed

Summary of tests:
a) motd message still displayed
b) cloud_id set to $cloudname in user-agent

Tested on: lxd, aws, gce, azure

Using package base-files 10.1ubuntu2.7 from bionic-proposed

Detailed test logs attached.

** Attachment added: "bionic-verification.txt"
   
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+attachment/5294435/+files/bionic-verification.txt

** Tags removed: verification-needed-bionic
** Tags added: verification-done-bionic

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-04 Thread Andreas Hasenack
Xenial verification: passed

Summary of tests:
No errors or warnings during package upgrade
a) motd message is now displayed
a.1) motd message displayed on login
b) cloud_id set to $cloudname in user-agent
c) motd-news.timer scheduled to run

Tested on: lxd, aws, gce, azure

Using package base-files 9.4ubuntu4.11 from xenial-proposed

Detailed test logs attached.

** Attachment added: "xenial-verification.txt"
   
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+attachment/5294436/+files/xenial-verification.txt

** Tags removed: verification-needed-xenial
** Tags added: verification-done-xenial

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-04 Thread Andreas Hasenack
Disco verification: passed

Summary of tests:
a) motd message still displayed
b) cloud_id set to $cloudname in user-agent

Tested on: lxd, aws, gce, azure

Using package base-files 10.1ubuntu9.2 from disco-proposed

Detailed test logs attached.

** Attachment added: "disco-verification.txt"
   
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+attachment/5294434/+files/disco-verification.txt

** Tags removed: verification-needed-disco
** Tags added: verification-done-disco

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-04 Thread Andreas Hasenack
The verification log is quite extensive and verbose, since it's about 3
ubuntu releases and on 4 clouds: lxd, aws, gce, azure. I'll post a
summary and an attachment with the detailed log for each.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-03 Thread Łukasz Zemczak
Hello Andreas, or anyone else affected,

Accepted base-files into xenial-proposed. The package will build now and
be available at https://launchpad.net/ubuntu/+source/base-
files/9.4ubuntu4.11 in a few hours, and then in the -proposed
repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed.  Your feedback will aid us getting this
update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested and change the tag from
verification-needed-xenial to verification-done-xenial. If it does not
fix the bug for you, please add a comment stating that, and change the
tag to verification-failed-xenial. In either case, without details of
your testing we will not be able to proceed.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance for helping!

N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.

** Changed in: base-files (Ubuntu Xenial)
   Status: In Progress => Fix Committed

** Tags added: verification-needed-xenial

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-10-03 Thread Łukasz Zemczak
Generally I'd say this is more of a feature than a bug-fix, so a bit
tricky from an SRU POV. But on the other hand, this does seem like
something we'd like to have in-sync for all stable series. The test case
is sufficiently well formed and regression potential thoroughly laid out
- this feels solid enough as far as acceptance criteria go.

** Changed in: base-files (Ubuntu Disco)
   Status: In Progress => Fix Committed

** Tags added: verification-needed verification-needed-disco

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-09-30 Thread Launchpad Bug Tracker
** Merge proposal linked:
   
https://code.launchpad.net/~ahasenack/ubuntu/+source/base-files/+git/base-files/+merge/373413

** Merge proposal linked:
   
https://code.launchpad.net/~ahasenack/ubuntu/+source/base-files/+git/base-files/+merge/373414

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-09-30 Thread Launchpad Bug Tracker
** Merge proposal linked:
   
https://code.launchpad.net/~ahasenack/ubuntu/+source/base-files/+git/base-files/+merge/373411

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840946

Title:
  Include cloud-id in user-agent string

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1840946/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1840946] Re: Include cloud-id in user-agent string

2019-09-30 Thread Andreas Hasenack
** Description changed:

  [Impact]
  
  We would like to include a cloud_id/$name parameter to the user-agent
  string that is sent to https://motd.ubuntu.com. This will allow the
  server part of motd.ubuntu.com to serve cloud-specific content if one is
  available.
  
+ [Test Case]
+ a) confirm that the motd message is still displayed:
+ $ sudo sh /etc/update-motd.d/50-motd-news --force
  
- [Test Case]
+  * Kata Containers are now fully integrated in Charmed Kubernetes 1.16!
+Yes, charms take the Krazy out of K8s Kata Kluster Konstruction.
  
-  * detailed instructions how to reproduce the bug
+  https://ubuntu.com/kubernetes/docs/release-notes
  
-  * these should allow someone who is not familiar with the affected
-    package to reproduce the bug and verify that the updated package fixes
-    the problem.
+ b) confirm that cloud_id is set in the user-agent. This should be tested
+ in lxd, gce, aws, and azure. Here is an example for lxd:
+ 
+ $ sudo sh -x /etc/update-motd.d/50-motd-news --force 2>&1| grep -E "curl 
.*cloud_id/"
+ + curl --connect-timeout 60 --max-time 60 -A curl/7.47.0-1ubuntu2.14 
Ubuntu/16.04.6/LTS GNU/Linux/4.15.0-64-generic/x86_64 
Intel(R)/Core(TM)/i7-7600U/CPU/@/2.80GHz uptime/921.00/900.00 cloud_id/lxd -o- 
https://motd.ubuntu.com
+ 
+ For each of the mentioned clouds, we expect cloud_id to be set to their
+ short names: aws, gce, azure.
  
  [Regression Potential]
+ This change adds a new parameter to the already existing user-agent string. 
This relies on the cloud-id tool from cloud-init. Even though it's considered 
trusted to some degree, it may be possible for some clouds to override their 
name in the data fed to cloud-init, which is what cloud-id parses. Therefore 
some precautions were taken when handling its contents:
+ - set value to unknown if cloud-id fails, doesn't exist, or produce an empty 
value
+ - sanitize the output of cloud-id, and truncate it to a maximum length
+ - use a tempfile to store the intermediate output of cloud-id instead of a 
shell variable. One reason being avoiding storing a potentially large amount of 
data in a shell variable, and the other is to avoid mistakes when manipulating 
a shell variable that could contain shell metacharacters.
  
-  * discussion of how regressions are most likely to manifest as a result
- of this change.
- 
-  * It is assumed that any SRU candidate patch is well-tested before
-    upload and has a low overall risk of regression, but it's important
-    to make the effort to think about what ''could'' happen in the
-    event of a regression.
- 
-  * This both shows the SRU team that the risks have been considered,
-    and provides guidance to testers in regression-testing the SRU.
  
  [Other Info]
- 
-  * Anything else you think is useful to include
-  * Anticipate questions from users, SRU, +1 maintenance, security teams and 
the Technical Board
-  * and address these questions in advance
+ For xenial, this is also finishing the fix for bug #1637800 which was stuck 
in the SRU queue due to it failing checks. Since the xenial package isn't using 
debhelper, manual dh snippets were added to the maintainer scripts, but they 
missed the dh_systemd_enable chunks. I'm also skipping starting 
motd-news.service, since the timer unit will handle that. This avoids an 
annoying error message about trying to start a unit that is not enabled.
  
  [Original Description]
  I'm preemptively filing this bug in case this isn't uploaded before the 
feature freeze.
  
  We would like to include a cloud_id/$name parameter to the user-agent
  string that is sent to https://motd.ubuntu.com. This will allow the
  server part of motd.ubuntu.com to serve cloud-specific content if one is
  available.
  
  There is an MP for this already at
  https://code.launchpad.net/~ahasenack/ubuntu/+source/base-files/+git
  /base-files/+merge/371370

** Description changed:

  [Impact]
  
  We would like to include a cloud_id/$name parameter to the user-agent
  string that is sent to https://motd.ubuntu.com. This will allow the
  server part of motd.ubuntu.com to serve cloud-specific content if one is
  available.
  
  [Test Case]
  a) confirm that the motd message is still displayed:
  $ sudo sh /etc/update-motd.d/50-motd-news --force
  
-  * Kata Containers are now fully integrated in Charmed Kubernetes 1.16!
-Yes, charms take the Krazy out of K8s Kata Kluster Konstruction.
+  * Kata Containers are now fully integrated in Charmed Kubernetes 1.16!
+    Yes, charms take the Krazy out of K8s Kata Kluster Konstruction.
  
-  https://ubuntu.com/kubernetes/docs/release-notes
+  https://ubuntu.com/kubernetes/docs/release-notes
  
  b) confirm that cloud_id is set in the user-agent. This should be tested
  in lxd, gce, aws, and azure. Here is an example for lxd:
  
  $ sudo sh -x /etc/update-motd.d/50-motd-news --force 2>&1| grep -E "curl 
.*cloud_id/"
  + curl --connect-timeout 60 --max-time 60 -A curl/7.47.0-1ubuntu2.14