ubuntu-cpc project: git empty directory handling

Bug #1794383 reported by Robert C Jennings
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
livecd-rootfs (Ubuntu)
Xenial
Fix Released
High
Unassigned

Bug Description

We use a LP build recipe that includes livecd-rootfs.
We are moving from bzr to git due to other projects moving to git.
When we import livecd-rootfs into git it does not commit empty
directories into the git tree. The livecd-build/ubuntu-
cpc/includes.chroot/etc/network/interfaces.d/ directory is dropped
when we do this import.

Foundations team would also like to move the upstream repositories to git including for stable releases, and this change would need to be made as part of this.

[Impact]

 * Importing the package and committing it to a git repository
   drops empty directories from the ubuntu-cpc/includes.chroot tree
 * Images built in the ubuntu-cpc project drop this directory which
   is a regression

[Test Case]

 * Create a bare git repo,
 * Pull the livecd-rootfs from xenial-updates into the repo,
 * Commit the code to git
 * Use the committed code (fresh clone) to build the ubuntu-cpc project
 * Inspect the images to see if /etc/network/interfaces.d exists

[Regression Potential]

 * Low. This create a directory via dh_installdirs if it doesn't exist
   already in the packaging. Builds from sources that include the
   empty directory are not be impacted. The owner and permissions on
   the directory are same.

Revision history for this message
Robert C Jennings (rcj) wrote :

This only exists in Xenial thus the patch is only relevant for that release.

Steve Langasek (vorlon)
description: updated
Revision history for this message
Steve Langasek (vorlon) wrote :

Have discussed out of band that the current directory location in the source package could be created declaratively via a debian/dirs that creates it in the binary package, rather than making this something that has to be created in a chroot hook.

Revision history for this message
Robert C Jennings (rcj) wrote :

I'll give that a go, get it tested, and update this bug.

Revision history for this message
Robert C Jennings (rcj) wrote :

Updated debdiff using debian/dirs rather than a chroot hook

Revision history for this message
Robert C Jennings (rcj) wrote :

I've tested the patch by building this with/without live-build/ubuntu-cpc/includes.chroot/etc/network/interfaces.d/ in the package (as it would if imported to bzr/git) and both result in a deb with the path we need (created through dh_installdirs when git drops the directory in the source).

Robert C Jennings (rcj)
description: updated
Robert C Jennings (rcj)
summary: - ubuntu-cpc project: Add a hack for git empty directory handling
+ ubuntu-cpc project: git empty directory handling
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "livecd-rootfs_2.408.37.debdiff" seems to be a debdiff. The ubuntu-sponsors team has been subscribed to the bug report so that they can review and hopefully sponsor the debdiff. If the attachment isn't a patch, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are member of the ~ubuntu-sponsors, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issue please contact him.]

tags: added: patch
Revision history for this message
Robie Basak (racb) wrote : Please test proposed package

Hello Robert, or anyone else affected,

Accepted livecd-rootfs into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/livecd-rootfs/2.408.37 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, details of your testing will help us make a better decision.

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

Changed in livecd-rootfs (Ubuntu Xenial):
status: New → Fix Committed
tags: added: verification-needed verification-needed-xenial
Revision history for this message
Robert C Jennings (rcj) wrote :

Following the test case I have verified that the packaging change produces the empty directory when imported into a git repository and re-building the package. Thank you.

tags: added: verification-done verification-done-xenial
removed: verification-needed verification-needed-xenial
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package livecd-rootfs - 2.408.37

---------------
livecd-rootfs (2.408.37) xenial; urgency=medium

  * debian/dirs: add debian/dirs entry for empty includes.chroot dir
    (LP: #1794383)

 -- Robert C Jennings <email address hidden> Tue, 25 Sep 2018 20:24:49 -0500

Changed in livecd-rootfs (Ubuntu Xenial):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for livecd-rootfs has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Mathew Hodson (mhodson)
no longer affects: livecd-rootfs (Ubuntu)
Changed in livecd-rootfs (Ubuntu Xenial):
importance: Undecided → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.