This commit is contained in:
2026-06-25 09:36:05 +07:00
parent d3fef38796
commit 5c644545b8
364 changed files with 78377 additions and 0 deletions
@@ -0,0 +1,64 @@
plugins {
id "jacoco"
id "org.sonarqube"
id "com.diffplug.spotless"
id "com.github.andygoossens.gradle-modernizer-plugin"
id "io.spring.nohttp"
}
jacoco {
toolVersion = "${libs.versions.jacoco.get()}"
}
jacocoTestReport {
executionData(tasks.withType(Test))
classDirectories.from = files(sourceSets.main.output.classesDirs)
sourceDirectories.from = files(sourceSets.main.java.srcDirs)
reports {
xml.required = true
}
}
file("sonar-project.properties").withReader {
Properties sonarProperties = new Properties()
sonarProperties.load(it)
sonarProperties.each { key, value ->
sonarqube {
properties {
property(key, value)
}
}
}
}
spotless {
java {
target 'src/*/java/**/*.java'
// removeUnusedImports()
}
}
modernizer {
failOnViolations = true
includeTestClasses = true
}
checkstyle {
toolVersion = "${libs.versions.checkstyle.get()}"
configFile = file("checkstyle.xml")
ignoreFailures = true
checkstyleTest.enabled = false
}
nohttp {
source.include("build.gradle", "README.md")
}
// workaround for https://github.com/checkstyle/checkstyle/issues/14123
configurations.checkstyle {
resolutionStrategy.capabilitiesResolution.withCapability("com.google.collections:google-collections") {
select("com.google.guava:guava:0")
}
}
@@ -0,0 +1,33 @@
plugins {
id "com.google.cloud.tools.jib"
}
jib {
configurationName = "productionRuntimeClasspath"
from {
image = "eclipse-temurin:25-jre-noble"
platforms {
platform {
architecture = "${findProperty('jibArchitecture') ?: 'amd64'}"
os = "linux"
}
}
}
to {
image = "sisvietnamvn:latest"
}
container {
entrypoint = ["bash", "-c", "/entrypoint.sh"]
ports = ["8080"]
environment = [
SPRING_OUTPUT_ANSI_ENABLED: "ALWAYS",
JHIPSTER_SLEEP: "0"
]
creationTime = "USE_CURRENT_TIMESTAMP"
user = 1000
}
extraDirectories {
paths = file("src/main/docker/jib")
permissions = ["/entrypoint.sh": "755"]
}
}