Skip to content
This repository has been archived by the owner on Feb 24, 2020. It is now read-only.

exit status 1 all the time? #164

Closed
cdrage opened this issue Feb 5, 2016 · 9 comments
Closed

exit status 1 all the time? #164

cdrage opened this issue Feb 5, 2016 · 9 comments

Comments

@cdrage
Copy link
Contributor

cdrage commented Feb 5, 2016

For some reason I'm getting this when building all the examples:

acbuild/examples/apache  master ✗                                                                                                                                                                                                                      30d ◒  
▶ sudo ./build-apache.sh
Beginning build with an empty ACI
Setting name of ACI to example.com/apache
Adding dependency "quay.io/coreos/alpine-sh"
Running: [apk update]
run: exit status 1
Ending the build

Any idea as to why? No debug info for this :(

@cdrage
Copy link
Contributor Author

cdrage commented Feb 5, 2016

Using:

acbuild/examples/apache  master ✗                                                                                                                                                                                                                     30d ◒  ⍉
▶ acbuild version
acbuild version v0.2.2-2-g46ad9c4
appc version 0.7.1+git

(master)

@cgonyeo
Copy link
Member

cgonyeo commented Feb 5, 2016

Related: #162

I'm aware of this as a problem, but have no clue what's causing it. I'll look into it soon.

@cdrage
Copy link
Contributor Author

cdrage commented Feb 5, 2016

@dgonyeo #162
Okay, so I think I may have found the problem.

If you build using:
acbuild --debug begin quay.io/listhub/alpine

it works fine (without adding dep)

but if you use it depending on the dep, it doesn't
acbuild --debug dep add quay.io/coreos/alpine-sh

issue with dep?
any ideas?

@cgonyeo
Copy link
Member

cgonyeo commented Feb 10, 2016

That may mean that there's some issue with overlayfs, I'll see if I can investigate further.

@cdrage
Copy link
Contributor Author

cdrage commented Feb 10, 2016

FYI, I'm building on Debian 8 with 3.16.0-4-amd64.

@cgonyeo
Copy link
Member

cgonyeo commented Feb 10, 2016

I think I may have had a friend who saw a similar, if not identical issue also in Debian once. Guess it's time to spin up a Debian vm.

@cgonyeo
Copy link
Member

cgonyeo commented Feb 10, 2016

Figured it out: acbuild doesn't print a useful error message when the overlayfs kernel module isn't available.

At this line: https://github.com/appc/acbuild/blob/master/lib/run.go#L83 acbuild execs modprobe overlay, and if an error is encountered it's simply returned. A much better behavior would be to detect when the error is exit code 1, which implies that the module failed to load. I'll make a PR.

For specifically debian, I found this, which says that overlayfs didn't make it into Linux until 3.18. It also looks like you can get the newer kernel from experimental, so I'd suggest you give that a shot if you want to get acbuild working in debian.

Alternatively if you avoid builds with dependencies, acbuild won't need overlayfs. You can modify the apache example by removing the line:

acbuild --debug dep add quay.io/coreos/alpine-sh

and replacing the line:

acbuild --debug begin

with

acbuild --debug beginquay.io/coreos/alpine-sh

@cgonyeo
Copy link
Member

cgonyeo commented Feb 10, 2016

#171

@cdrage
Copy link
Contributor Author

cdrage commented Feb 10, 2016

Thanks 👯 !

@cdrage cdrage closed this as completed Feb 10, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants