Hi *,

Quick notice: I spent some time hacking to get Phabricator to build
code reviews you publish against the GHC repository. It luckily was
not that hard to do so - hooray!

Go here for an example:

https://phabricator.haskell.org/D64

Look at the top set of information, and find 'Build Status'. This
points to the current build being produced for this revision. Icon
colors are - red is failed, blue is in progress, green means good.

The build is driven by an application called 'Harbormaster'.
Harbormaster makes an HTTP request when a new diff is posted, which
triggers a build on a backend system that applies the diff and runs
./validate.

Now, look at this specific link:

https://phabricator.haskell.org/D64#16

I updated the diff, and the build failed and notified Harbormaster.
This adds a notification to the page (just below the comment I
linked), emails interested parties, and marks the build status at the
top.

After a build happens, a bot named `phaskell` will drop by and give
some results. Validate logs are gzip'd, and uploaded to Phabricator as
.txt.gz files. You can download them and look at the full results. If
the build fails, the tests that failed are output in the comment on
the revision automatically.

Builds happen per diff. This means they happen every time you run 'arc diff'.

This is all extremely new. Please be nice to it. :) However - if you
have some cool changes, please post them! I might just post some to
let it do ./validate - it's nice if the machines can just do the work
and you can be lazy. :)

In the future, Phabricator's Drydock and Harbormaster applications
will expand to hopefully do this on their own, with no custom
infrastructure from us. We can also utilize resources more
effectively.

Here's where you can look for the current build queue:

https://phabricator.haskell.org/harbormaster/query/all/

The build queue is currently serial - that means the system only runs
one build at a time on a 4 core dedicated machine. This simplifies the
management but it does mean it could get slightly backed up. It's only
a 30 minute wait to validate something though, and that can probably
be improved further.

Next up: Linking Phabricator to Trac.

P.S. The way it works technically is Phabricator -> HTTP GET -> Build
machine. This machine runs an HTTP Server - a Python Flask server that
simply runs a build script, which reports back to
phabricator.haskell.org with JSON requests. Phabricator requests are
HTTPS secured. GET requests are securely tunneled over an encrypted
pipe (spiped). This build script update Harbormaster's status, post
comments, and uploads the build log.

Source code: https://github.com/haskell-infra/phab-ghc-builder

-- 
Regards,

Austin Seipp, Haskell Consultant
Well-Typed LLP, http://www.well-typed.com/
_______________________________________________
ghc-devs mailing list
ghc-devs@haskell.org
http://www.haskell.org/mailman/listinfo/ghc-devs

Reply via email to