Support building rkt inside rkt container #1681
Conversation
cd1d052
to
2e18738
Compare
Awesome! This could be used to build future releases of rkt. |
--volume build-dir,kind=host,source=$BUILD_DIR \ | ||
--interactive \ | ||
--insecure-skip-verify \ | ||
$RKT_BUILDER_ACI \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here, $RKT_BUILDER_ACI
can be either a local file or the aci from coreos.com
.
--insecure-skip-verify
should only be use if we work on a local file since we don't want to disable gpg signature checks when downloading from internet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wasn't sure how to handle this since currently the ACI isn't published anywhere (nor am I sure on how that will end up working). Since this PR expects it to be a local ACI to be imported into the CAS can I leave this for now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or: since it's been fetched already I shouldn't need that flag I guess?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
@alban Also removed the |
FLAGS=${FLAGS:-""} | ||
IMG=${IMG:-"debian"} | ||
IMGVERSION=${VERSION:-"sid"} | ||
DOCKERIMG="$IMG:$VERSION" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/VERSION/IMGVERSION
@iaguis Addressed the comments. |
|
||
echo "Building $ACIFILE" | ||
|
||
which docker2aci || go get github.com/appc/docker2aci |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider checking if GOPATH environment variable is set and if it is not, set it to something local, otherwise go get
will fail.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh yeah, and when setting GOPATH, probably PATH will need to be adapted to point to bin dir in GOPATH.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OTOH, there are no checks for actool
. We can do one of two things for actool, docker2aci and acbuild:
which $TOOL || go get $TOOL_AT_GITHUB_OR_ELSE
if ! which tool; then echo "get $TOOL and put it in yer $PATH" >&2; exit 1; fi
I'd like to see this for 0.13.0. @ecnahc515 think you'll have time within the next 2 weeks? otherwise please unassign and mark as help wanted |
@jonboulle I could probably take the time today/tomorrow to do this i think. |
superb, thanks! On Wed, Nov 25, 2015 at 11:19 AM, Chance Zibolski notifications@github.com
|
@ecnahc515 are you going to be able to get to this or should we reassign to someone else? |
Okay, so I've gotten this up to date, rebased on master, and addressed the issues. I had to make other changes, but everything should be essentially how it worked before. I had a few questions regarding the Ex, currently it produces Deciding on this will be important when you want to push the builder image to some kind of repository, otherwise you'll have no easy way of distinguishing which builder your using. Just a note, if you attempt this right now, you'll need to run acbuild on master with containers/build#134 applied as well. |
@@ -0,0 +1,107 @@ | |||
# coreos.com/rkt/builder | |||
|
|||
This container contains all build-time dependencies in order to build rkt. It |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use one sentence per line for now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done in c9a610c
@krnowak I think I've addressed all your comments. I can rebase the last commits once everything looks good to merge. |
LFAD. |
Support building rkt inside rkt container
@ecnahc515: Thanks for your work! |
This adds some new scripts and documentation details on how to use
acbuild
to create an ACI which has all build-time dependencies for compiling rkt, as well as how to use said image to compile rkt and output the result into a volume.Vagrant still builds in the VM, not in a container, it would be slower to do it in a container because the image would need to be built first, but once we can pull in the builder image, it should be switched to use that & rkt for builds. Also, when rkt is being built in vagrant, the it now logs to
/vagrant/rkt-build.log
, because vagrant was printing the wget progress bar terribly (one line per dot blink), so if it looks like nothing is happening during the build, that's why.Fixes #844