Skip to content

Conversation

@pks-t
Copy link
Member

@pks-t pks-t commented Apr 21, 2017

Ubuntu 12.04 (Precise Pangolin) reaches end of life on April 28th, 2017.
As such, we should update our build infrastructure to use the next
available LTS release, which is Ubuntu 14.04 LTS (Trusty Tahr). Note
that Trusty is still considered beta quality on Travis. But considering
we are able to correctly build and test libgit2, this seems to be a
non-issue for us.

Switch over our default distribution to Trusty. As Precise still has
extended support for paying customers, add an additional job which
compiles libgit2 on the old release.

@pks-t
Copy link
Member Author

pks-t commented Apr 21, 2017

Well. Seems I've been too keen on this one. We certainly cannot "correctly build and test", as there is an issue with the SSH key exchange. Will investigate

@pks-t
Copy link
Member Author

pks-t commented Apr 25, 2017

So the problem is related to the SSH server not running in the new images. Previously, it has only been working by accident: by default, sshd is already installed but not running in Precise images. But as the version is out-of-date, we upgrade openssh-server and then also start it in the process. For Trusty, the package is already up-to-date and as such will not be reinstalled. As a consequence, no post-upgrade hooks are executed and sshd will not get executed.

Unfortunately, we are unable to start the sshd executable ourselves, as we currently run in sudo-less containers. Three possibilities:

  1. query the Travis team
  2. disable SSH-related tests if the server is not running
  3. switch from sudo-less containers to a fully virtualized virtual machine

The second option is not really an option in the long run, I guess. The third option has downsides regarding performance, as the initial startup of the VM has around ~45 seconds overhead. There'll probably more performance degradations at runtime due to being virtualized. So the first option is obviously the best one, but will take longer than the others.

@pks-t
Copy link
Member Author

pks-t commented Apr 25, 2017

I take that back. As it seems, sshd is running... back to zero

@pks-t
Copy link
Member Author

pks-t commented Apr 25, 2017

So the issue is that sshd is missing host keys. We're not able to generate them, as again we're running sudoless. I've created an issue with Travis at travis-ci/travis-ci#7661.

@pks-t pks-t force-pushed the pks/trusty branch 2 times, most recently from 755ffe1 to 53ce090 Compare April 26, 2017 13:03
@pks-t
Copy link
Member Author

pks-t commented Apr 26, 2017

This sucks. We actually have one failing test with the poxyproxy. It causes a segfault in libcurl when it checks whether the established connection is already authenticated via NTLM. While our parameters seem to be set correctly, the connection which is checked against has NULL user and passwd, which are then passed to strcmp.

So I'm not even sure if it is us or libcurl. I think it's libcurl's fault, but I'm not too sure about this. Dunno what to do about it, though.

@pks-t pks-t force-pushed the pks/trusty branch 2 times, most recently from e9c3a74 to b6daccc Compare May 2, 2017 13:02
@pks-t
Copy link
Member Author

pks-t commented May 2, 2017

Seems they fixed the build environment now. I've done multiple builds, no failures up to now. So I guess this is ready to be merged

@ethomson
Copy link
Member

ethomson commented May 2, 2017

Excellent. Let's merge this right after we ship an 0.26.0.

@pks-t
Copy link
Member Author

pks-t commented May 3, 2017

Agreed. One potential benefit by upgrading is that the libcurl warning is not present anymore, so we are even able to enable -Werror for Trusty containers. There are a few other warnings, but they are trivial to fix.

@pks-t pks-t force-pushed the pks/trusty branch 5 times, most recently from f2ab494 to b8537bd Compare May 3, 2017 11:56
@pks-t pks-t mentioned this pull request May 15, 2017
pks-t added 3 commits June 21, 2017 08:05
All our tests running against a local SSH server usually read the
server's URL from environment variables. But online::clone::ssh_cert
test fails to do so and instead always connects to
"ssh://localhost/foo". This assumption breaks whenever the SSH server is
not running on the standard port, e.g. when it is running as a user.

Fix the issue by using the URL provided by the environment.
Some tests of ours require to be running against an SSH server.
Currently, we simply run against the SSH server provided and started by
Travis itself. As our Linux tests run in a sudo-less environment, we
have no control over its configuration and startup/shutdown procedure.
While this has been no problem until now, it will become a problem as
soon as we migrate over to newer Precise images, as the SSH server does
not have any host keys set up. Luckily, we can simply set up our own
unpriviledged SSH server. This has the benefit of us being able to
modify its configuration even in a sudo-less environment.

This commit sets up the unpriviledged SSH server on port 2222.
Ubuntu 12.04 (Precise Pangolin) reaches end of life on April 28th, 2017.
As such, we should update our build infrastructure to use the next
available LTS release, which is Ubuntu 14.04 LTS (Trusty Tahr). Note
that Trusty is still considered beta quality on Travis. But considering
we are able to correctly build and test libgit2, this seems to be a
non-issue for us.

Switch over our default distribution to Trusty. As Precise still has
extended support for paying customers, add an additional job which
compiles libgit2 on the old release.
@pks-t
Copy link
Member Author

pks-t commented Jun 21, 2017

Dropping the -Werror patch for now. I'll probably create a new PR later to switch it on.

@ethomson ethomson merged commit 62c44c4 into libgit2:master Jun 21, 2017
@pks-t pks-t mentioned this pull request Jun 23, 2017
@pks-t pks-t deleted the pks/trusty branch September 15, 2017 06:02
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.

2 participants