diff --git a/generators/server/templates/gradle/docker.gradle.ejs b/generators/server/templates/gradle/docker.gradle.ejs index 70b5a49d..27879902 100644 --- a/generators/server/templates/gradle/docker.gradle.ejs +++ b/generators/server/templates/gradle/docker.gradle.ejs @@ -17,9 +17,9 @@ dockerfileNative { baseImage = "oracle/graalvm-ce:20.3.0-java11" args("-Xmx64m") } -nativeImage { - args('--static') -} + + + dockerBuildNative { images = ["<%= baseName %>:$project.version", "<%= baseName %>:latest"] } diff --git a/generators/server/templates/src/test/java/package/config/CorsController.java.ejs b/generators/server/templates/src/test/java/package/config/CorsController.java.ejs index f100c421..67b1a3a5 100644 --- a/generators/server/templates/src/test/java/package/config/CorsController.java.ejs +++ b/generators/server/templates/src/test/java/package/config/CorsController.java.ejs @@ -2,8 +2,11 @@ package <%=packageName%>.config; import io.micronaut.http.annotation.Controller; import io.micronaut.http.annotation.Get; +import io.micronaut.security.annotation.Secured; +import io.micronaut.security.rules.SecurityRule; @Controller +@Secured(SecurityRule.IS_ANONYMOUS) public class CorsController { @Get("/api/test-cors")