Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move Debian tests from unstable to testing #5726

Closed

Conversation

martinpitt
Copy link
Member

This will unblock issues like in PR #5714.

I'm currently building a debian-testing image locally and will run tests against it and check that storaged works against debian testing too (I don't expect any difficulties, though).

@martinpitt
Copy link
Member Author

Unfortunately building an image for Debian testing doesn't currently work either:

Package docker.io is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'docker.io' has no installation candidate

It got kicked out of testing three months ago because it has too many release-critical bugs.

@martinpitt martinpitt force-pushed the debian-move-to-testing branch 2 times, most recently from 6440b6c to 6be8958 Compare January 11, 2017 15:53
@martinpitt
Copy link
Member Author

I worked around the docker.io issue by adding jessie-backports, pushed. I also took the liberty to change the mirror to the automatic/GeoIP aware redirector for faster local builds. Please let me know if ftk.uk.d.o. must be used because of some firewall rules or similar.

@dperpeet
Copy link
Contributor

I also took the liberty to change the mirror to the automatic/GeoIP aware redirector for faster local builds. Please let me know if ftk.uk.d.o. must be used because of some firewall rules or similar.

This is good and maybe deserves its own commit.

@martinpitt
Copy link
Member Author

Note to self: move jessie-backports enabling to test/images/scripts/debian-testing.setup, alongside enabling experimental. Fits better there.

@martinpitt martinpitt force-pushed the debian-move-to-testing branch 3 times, most recently from 60c35d5 to d94b245 Compare January 11, 2017 17:04
@martinpitt
Copy link
Member Author

martinpitt commented Jan 11, 2017

Pushed again, image building gets further now. Now it fails with the pbuilder pre-caching:

The following packages have unmet dependencies:
 libssh-dev : Depends: libssl1.0-dev but it is not going to be installed
 npm : Depends: node-gyp (>= 0.10.9) but it is not going to be installed

In testing libssh-dev still depends on libssl1.0-dev while nodejs-dev (dependency of npm) already moved to OpenSSL 1.0 (libssl-dev), so they are not co-installable. This should hopefully clear up in 6 days (https://tracker.debian.org/news/830414).

@mvollmer
Copy link
Member

I also took the liberty to change the mirror to the automatic/GeoIP aware redirector for faster local builds. Please let me know if ftk.uk.d.o. must be used because of some firewall rules or similar.

This is good and maybe deserves its own commit.

Didn't we try this and had to revert to ftp.uk.d.o because the mirrors were frequently unreliable? But I am all for trying again.

@fsateler
Copy link

I also took the liberty to change the mirror to the automatic/GeoIP aware redirector for faster local builds. Please let me know if ftk.uk.d.o. must be used because of some firewall rules or similar.

This is good and maybe deserves its own commit.

Didn't we try this and had to revert to ftp.uk.d.o because the mirrors were frequently unreliable? But I am all for trying again.

I think http://deb.debian.org/ is the new "global" recommendation (it is backed by 2 cdns, fastly and cloudfront).

@martinpitt
Copy link
Member Author

I reworked this to drop the pcp dependencies and the cockpit-pcp package when building for debian-testing, as this is under-maintained and rather broken (uninstallable in unstable, not available in testing). The structure of this makes it relatively easy to put it back once it's available again.

Building a "debian-testing" image and preparing the test suite on it (i. e. package build, etc.) now worked locally, so I'll request an image build; I can work on adjusting the pcp test to be conditional while the infra is cranking out the new image.

@@ -46,6 +46,9 @@ if [ -n "$do_build" ]; then
tar -xzf cockpit-*.tar.gz
( cd cockpit-*/
cp -rp tools/debian debian
# Hack: Remove PCP build dependencies while pcp is not in testing
# (https://tracker.debian.org/pcp)
sed -i '/libpcp.*-dev/d' debian/control
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems this situation would prevent us from doing our weekly releases against Debian Testing? Broader question: Should we only be doing weekly releases against Jessie, and drop everything else?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To the contrary, this PR now would start to allow us doing weekly releases into unstable/testing as a new cockpit can actually propagate. It can't while it build/binary depends on pcp which isn't available in testing, and at the moment we can't even build cockpit with PCP in unstable.

The price is of course to drop the -pcp binary for the time being, but that's still better than dropping cockpit entirely IMHO.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... oh, that of course means that we have to drop the pcp build deps from the actual upload. If we can do this more elegantly someplace else, I'm all for it of course.

A different approach would be to use build dependency alternatives like pcp-dev | aspell-doc so that the builders install the (harmless) aspell-doc if pcp is not available. But this is really quite a hack and not even guaranteed to work on Debian builders (I know that Ubuntu's builders try alternate build dependencies, but Debian's didn't in the past), so I'd rather do the uploads in a way that the uploaded source package has the pcp build deps removed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The continuous delivery scripts are here:

https://github.com/cockpit-project/cockpituous/blob/master/release/release-dsc

https://github.com/cockpit-project/cockpituous/blob/master/release/release-debian

https://github.com/cockpit-project/cockpituous/blob/master/release/release-ubuntu-ppa

There's very little Cockpit specific in the Debian continuous delivery scripts, and we should be working towards removing the last remaining Cockpit specific bits.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the pointer. Indeed there are two seds in there for mangling debian/rules already. If we want to generalize those, how about instead calling a debian/rules prepare-dsc target or a debian/prepare-dsc.sh from cockpituous, and keep the project specific bits in cockpit itself?

This should also get a release or series argument (passed from release-{debian,ubuntu}) so that the mangling can be release specific and release-dsc can actually put it into the changelog too (instead of experimental).

Copy link
Contributor

@stefwalter stefwalter Jan 16, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like that. But lets take it a step further:

  1. if -s or RELEASE_DEBIAN is a directory, then use it directly as a debian directory.
  2. If -s or RELEASE_DEBIAN points to an executable, then execute it to produce a debian directory.

That said, in either case, how would we pass in information about which distribution we're creating an DSC for? Also currently we create one DSC and use it for multiple distributions, and then munge it further in release-debian ... however I'm not against creating multiple DSC files that are distribution appropriate right from release-dsc.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quick adjustment is in cockpit-project/cockpituous#66

@martinpitt
Copy link
Member Author

bot: Image refresh for debian-testing

@martinpitt
Copy link
Member Author

Uploaded manually, as the bot doesn't work for this yet: https://fedorapeople.org/groups/cockpit/images/debian-testing-c4971ea174fe44f14239d555c1fd0c9def9d84a1.qcow2.xz

Thus this should work now.

@stefwalter stefwalter changed the title WIP: Move Debian tests from unstable to testing Move Debian tests from unstable to testing Jan 16, 2017
Copy link
Contributor

@stefwalter stefwalter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmmm, I think if we're removing the test/images/debian-unstable link then we need to remove "debian-unstable" from test/common and friends.

@martinpitt
Copy link
Member Author

OK, I locally removed the remaining traces of "debian-unstable". I'll wait with pushing until the debian-testing test finishes, if the currently linked log is already current there are some failures there which look systematic (old docker.io?).

@stefwalter
Copy link
Contributor

You need this diff:

diff --git a/test/verify/check-realms b/test/verify/check-realms
index 3fa972d..882c051 100755
--- a/test/verify/check-realms
+++ b/test/verify/check-realms
@@ -45,7 +45,7 @@ def prepare_resolv(machine, address):
     machine.execute(script=RESOLV_SCRIPT.format(address=address))
 
 @skipImage("No realmd available", "continuous-atomic", "fedora-atomic", "rhel-atomic")
-@skipImage("No freeipa available", "debian-8")
+@skipImage("No freeipa available", "debian-8", "debian-testing")
 class TestRealms(MachineCase):
     additional_machines = {
         'ipa': { 'machine': { 'image': 'ipa' } }
@@ -196,7 +196,7 @@ getent passwd admin@cockpit.lan
 
 # This is here because our test framework can't run ipa VM's twice
 @skipImage("No realmd available", "continuous-atomic", "fedora-atomic", "rhel-atomic")
-@skipImage("No freeipa available", "debian-8")
+@skipImage("No freeipa available", "debian-8", "debian-testing")
 class TestKerberos(MachineCase):
     additional_machines = {
         'ipa': { 'machine': { 'image': 'ipa' } }

martinpitt and others added 10 commits January 17, 2017 21:17
Also enable jessie-backports in the bootstrap script until docker.io
gets back into testing (https://tracker.debian.org/news/804615). Restart
docker after installing everything, so that it starts with the aufs
backend (aufs-dkms might be installed after docker.io).

Drop freeipa-client as this is only in unstable due to too many
release-critical bugs.
Set dpkg's unsafe-io option to avoid fsyncing after unpacking every
file, for greatly speaking up package installation.

Don't download long package descriptions, we don't need those and they
take considerable time on apt-get update.
This is an automatic mirror redirector, see <http://deb.debian.org>.
It will soon get dropped from the actual Debian packaging
(cockpit-project#5710) and gets in the
way in debian-testing due to some packages using libssl1.0-dev still.
pcp is currently not available in Debian testing and
uninstallable/broken in unstable, so drop it from the image build and
pbuilder. See https://tracker.debian.org/pkg/pcp for details.

Skip the corresponding TestMetrics.testPcp() test case.
Current Debian testing, and maybe future Debian/Ubuntu releases don't have pcp.
Do not build the cockpit-pcp package either in that case.
It transitively gets pulled in through pcp, but when building without
that it failed with

  ./tools/tap-driver: /usr/bin/python: bad interpreter: No such file or directory
This avoids getting broken images and broken tests when any of the
imports fail for some reason.
We don't install ntpd into our test images, and if ntp.service does not
exist the TestSystemInfo.testTime test fails with

  CalledProcessError: Command 'systemctl stop ntp' returned non-zero exit status 5
Something in the virt-builder/upgrade chain causes sshd_config to have
"#PermitRootLogin prohibit-password" (i. e. being commented out). Make
the sed accept that.

This fixes check-dashboard TestDashboardSetup.testSetup.
@martinpitt
Copy link
Member Author

Can reproduce, pushed.

@martinpitt
Copy link
Member Author

FTR, all debian-8 tests pass locally for me, production seems to have some connection trouble to github ATM. In yesterday's test attempt there was only one failure on debian-8 which looked random.

stefwalter pushed a commit that referenced this pull request Jan 18, 2017
Set dpkg's unsafe-io option to avoid fsyncing after unpacking every
file, for greatly speaking up package installation.

Don't download long package descriptions, we don't need those and they
take considerable time on apt-get update.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
This is an automatic mirror redirector, see <http://deb.debian.org>.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
It will soon get dropped from the actual Debian packaging
(#5710) and gets in the
way in debian-testing due to some packages using libssl1.0-dev still.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
pcp is currently not available in Debian testing and
uninstallable/broken in unstable, so drop it from the image build and
pbuilder. See https://tracker.debian.org/pkg/pcp for details.

Skip the corresponding TestMetrics.testPcp() test case.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
Current Debian testing, and maybe future Debian/Ubuntu releases don't have pcp.
Do not build the cockpit-pcp package either in that case.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
It transitively gets pulled in through pcp, but when building without
that it failed with

  ./tools/tap-driver: /usr/bin/python: bad interpreter: No such file or directory

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
This avoids getting broken images and broken tests when any of the
imports fail for some reason.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
We don't install ntpd into our test images, and if ntp.service does not
exist the TestSystemInfo.testTime test fails with

  CalledProcessError: Command 'systemctl stop ntp' returned non-zero exit status 5

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
stefwalter pushed a commit that referenced this pull request Jan 18, 2017
Something in the virt-builder/upgrade chain causes sshd_config to have
"#PermitRootLogin prohibit-password" (i. e. being commented out). Make
the sed accept that.

This fixes check-dashboard TestDashboardSetup.testSetup.

Closes #5726
Reviewed-by: Stef Walter <stefw@redhat.com>
@martinpitt martinpitt deleted the debian-move-to-testing branch January 18, 2017 10:07
stefwalter pushed a commit to cockpit-project/cockpituous that referenced this pull request Jan 19, 2017
…ting

pcp has release-critical bugs and fell out of testing, see
https://tracker.debian.org/pkg/pcp. Drop the pcp build dependencies when
building for unstable so that the package can be used on
testing/stretch.

This requires cockpit-project/cockpit#5726 so
that the package actually builds without these build dependencies.

Closes #66
Reviewed-by: Stef Walter <stefw@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants