-
Notifications
You must be signed in to change notification settings - Fork 887
Conversation
0e3ef95
to
b422fc7
Compare
With the feedback from docker2aci I rewrote it with a better algorithm so now it will create a list of files to extract for every aci. This list can be used by another function to directly create a tar (like needed by docker2aci, or to extract it to a filesystem, like the original acirenderer). The extraction part is in its file (extract.go) so this can also be splitted and the acirenderer core, if needed, can be moved to another place. PTAL. |
cfa7cbe
to
a2b7cba
Compare
"github.com/appc/spec/schema/types" | ||
) | ||
|
||
// An ACIRegistry provides al functions of an ACIProvider plus functions to |
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.
al -> all
|
||
// ACIFiles represent which files to extract for every ACI | ||
type ACIFiles struct { | ||
key string |
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 need these exported if I want to access them later
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.
Right. Done!
f0189b7
to
f66d327
Compare
@iaguis @jonboulle Thanks a lot for your review! I tried to fix all the comments (let me know if someone was left behind). In the meantime I added an additional test with a 3 depth dependencies tree. |
555d108
to
7bed0b3
Compare
@iaguis @jonboulle In the meantime I fixed an error in getUpperPwlm, added a test and docs for it. |
7bed0b3
to
0f4933e
Compare
@jonboulle @iaguis if you're ok I'd like to PR the acirenderer core to appc/spec (or appc/tools or whatever you prefer) as suggested in appc/docker2aci#10 and open another PR for the rocket part. |
That would be great but I'm not sure where it should go. I'm leaning towards something like appc/tools since this is only one implementation of rendering and things in the spec should be more general. @jonboulle? |
a7c33cc
to
35bc3fb
Compare
This library renders an aci given a well defined list of dependencies. A future patch will also provide the dependency resolving logic. It adds two interfaces: ACIProvider and ACIRegistry. The first interface is the one used by this patch and the cas has been changed to satisfy it. The second interface will be used by the dependency resolution functions. Also this interface is satisfied by the cas.
35bc3fb
to
4a20351
Compare
Use a copy of acirenderer as proposed in rkt/rkt#464 and rkt/rkt#465.
@jonboulle suggested OOB that since it's not that much code, we could put acirenderer in appc/spec/actool in anticipation of splitting it out into a different repo soon. I'm not sure if it makes sense conceptually to put it there but it would work and I'd like to move forward with this. So #465 would have to be moved to appc/spec/actool too but #533 and #322 would stay in rocket, along with the remaining DB stuff (#393 , #394, #395) and the tree cache (#332). What do you guys think about it? |
@jonboulle Talking on irc with @iaguis we thought about proposing this and #465 to appc/spec/pkg/acirenderer. What do you think about it? (in the meantime I'll prepare the PRs 😄 ) |
Seems reasonable, thanks! On Fri, Feb 20, 2015 at 6:31 AM, Simone Gotti notifications@github.com
|
Yes, appc/spec#216 superseded this |
thanks @iaguis |
Sorry, I forgot to close this! |
This is the split of #297 in two parts. This first patch is the pure acirendering without any dependency resolving. It can be commited alone without any previous PR.
I hope it should also be useful for appc/docker2aci#6
This library renders an aci given a well defined list of dependencies.
A future patch will also provide the dependency resolving logic.
It adds two interfaces: ACIProvider and ACIRegistry.
The first interface is the one used by this patch and the cas has been changed
to satisfy it.
The second interface will be used by the dependency resolution functions. Also
this interface is satisfied by the cas.