затем запуск из Netbeans
развертывает и запускает war
, но:
nicholas@mordor:~/NetBeansProjects/x$
nicholas@mordor:~/NetBeansProjects/x$ gradle tasks --all
> Task :tasks
------------------------------------------------------------
Tasks runnable from root project 'x'
------------------------------------------------------------
Build tasks
-----------
assemble - Assembles the outputs of this project.
build - Assembles and tests this project.
buildDependents - Assembles and tests this project and all projects that depend on it.
buildNeeded - Assembles and tests this project and all projects it depends on.
classes - Assembles main classes.
clean - Deletes the build directory.
jar - Assembles a jar archive containing the main classes.
testClasses - Assembles test classes.
war - Generates a war archive with all the compiled classes, the web-app content and the libraries.
Build Setup tasks
-----------------
init - Initializes a new Gradle build.
wrapper - Generates Gradle wrapper files.
Documentation tasks
-------------------
javadoc - Generates Javadoc API documentation for the main source code.
Help tasks
----------
buildEnvironment - Displays all buildscript dependencies declared in root project 'x'.
dependencies - Displays all dependencies declared in root project 'x'.
dependencyInsight - Displays the insight into a specific dependency in root project 'x'.
help - Displays a help message.
javaToolchains - Displays the detected java toolchains.
outgoingVariants - Displays the outgoing variants of root project 'x'.
projects - Displays the sub-projects of root project 'x'.
properties - Displays the properties of root project 'x'.
tasks - Displays the tasks runnable from root project 'x'.
Verification tasks
------------------
check - Runs all checks.
jacocoTestCoverageVerification - Verifies code coverage metrics based on specified rules for the test task.
jacocoTestReport - Generates code coverage report for the test task.
test - Runs the unit tests.
Other tasks
-----------
compileJava - Compiles main Java source.
compileTestJava - Compiles test Java source.
components - Displays the components produced by root project 'x'. [deprecated]
dependentComponents - Displays the dependent components of components in root project 'x'. [deprecated]
model - Displays the configuration model of root project 'x'. [deprecated]
prepareKotlinBuildScriptModel
processResources - Processes main resources.
processTestResources - Processes test resources.
Rules
-----
Pattern: clean<TaskName>: Cleans the output files of a task.
Pattern: build<ConfigurationName>: Assembles the artifacts of a configuration.
BUILD SUCCESSFUL in 686ms
1 actionable task: 1 executed
nicholas@mordor:~/NetBeansProjects/x$
nicholas@mordor:~/NetBeansProjects/x$ cat build.gradle
apply plugin: 'java'
apply plugin: 'jacoco'
apply plugin: 'war'
repositories {
mavenCentral()
}
dependencies {
providedCompile 'javax:javaee-web-api:8.0'
testImplementation 'junit:junit:4.13'
}
nicholas@mordor:~/NetBeansProjects/x$
Я не вижу явной задачи развертывания.
Как тогда Netbeans
развертывает файл war
?
Я не уверен, что это делается через gradle, но я думаю, что с помощью плагина wildfly.