-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
_skaffold-init task multimodule logic issues #2262
Comments
Don't forget to check GoogleContainerTools/skaffold#2844 |
This seems like an improvement, but the problem now is that when the goal runs on a multi-module project, the goal runs on all of the sub-modules first before running on the parent. This means for the
I think the intended behavior is to only print the last 2 JSON structs, correct? It seems like the |
should we force it to only run on the parent? |
Actually, my mistake. Was running the wrong version of Jib on the submodules. It looks like this does work. |
For posterity, I'll chime in to say my issue is now fixed. Before $ skaffold init --XXenableJibInit --analyze | jq .
{
"builders": [
{
"name": "Jib Maven Plugin",
"payload": {
"path": "pom.xml"
}
},
{
"name": "Jib Maven Plugin",
"payload": {
"path": "pom.xml"
}
},
{
"name": "Docker",
"payload": {
"path": "backend/Dockerfile"
}
},
{
"name": "Docker",
"payload": {
"path": "frontend/Dockerfile"
}
}
],
"images": [
{
"name": "java-guestbook-backend",
"foundMatch": false
},
{
"name": "java-guestbook-frontend",
"foundMatch": false
},
{
"name": "mongo",
"foundMatch": false
}
]
} After $ skaffold init --XXenableJibInit --analyze | jq .
{
"builders": [
{
"name": "Jib Maven Plugin",
"payload": {
"path": "pom.xml",
"project": "org.springframework.boot:frontend"
}
},
{
"name": "Jib Maven Plugin",
"payload": {
"path": "pom.xml",
"project": "org.springframework.boot:backend"
}
},
{
"name": "Docker",
"payload": {
"path": "backend/Dockerfile"
}
},
{
"name": "Docker",
"payload": {
"path": "frontend/Dockerfile"
}
}
],
"images": [
{
"name": "java-guestbook-backend",
"foundMatch": false
},
{
"name": "java-guestbook-frontend",
"foundMatch": false
},
{
"name": "mongo",
"foundMatch": false
}
]
} |
@balopat @jonjohnsonjr we've released Jib 2.1.0, which fixes this issue. |
The issues with the current logic (at least in the maven plugin, gradle task might have the same issues):
artifactId
instead of the module name to return aproject
which is a problem as that is interpreted on the skaffold side as a directoryI won't have time to fully implement the thing with tests and everything, but as I played around with the code this seemed to do the job altogether:
The text was updated successfully, but these errors were encountered: