How do I create a hadoop jar that includes all dependencies in the lib folder using Gradle? Basically开发者_运维知识库, similar to what fatjar does.
Figured it out! Hadoop looks for libraries inside the "lib" folder of the final jar. So, add the following to the "jar" task.
jar {
doFirst {
into('lib') {
from configurations.runtime
}
}
}
精彩评论