import com.bmuschko.gradle.docker.tasks.image.DockerBuildImage
import com.bmuschko.gradle.docker.tasks.image.DockerPushImage

plugins {
    id 'java'
    id 'io.quarkus'
    id "com.bmuschko.docker-remote-api" version "${dockerPluginVersion}"
    id "com.diffplug.gradle.spotless" version "${spotlessPluginVersion}"
    id "com.github.ben-manes.versions" version "${versionsPluginVersion}"
    id "se.patrikerdes.use-latest-versions" version "${useLatestVersionsPluginVersion}"
}

sourceCompatibility = 11
targetCompatibility = 11

repositories {
     mavenLocal()
     mavenCentral()
}

tasks {
    dependencyUpdates {
        checkConstraints = true
        gradleReleaseChannel = "current"
        revision = "release"
    }
}

dependencies {
    implementation enforcedPlatform("${quarkusPlatformGroupId}:${quarkusPlatformArtifactId}:${quarkusPlatformVersion}")

    implementation 'io.quarkus:quarkus-agroal'
    implementation 'io.quarkus:quarkus-elytron-security-properties-file'
    implementation 'io.quarkus:quarkus-flyway'
    implementation 'io.quarkus:quarkus-hibernate-orm-panache'
    implementation 'io.quarkus:quarkus-hibernate-validator'
    implementation 'io.quarkus:quarkus-jdbc-postgresql'
    implementation 'io.quarkus:quarkus-kubernetes'
    implementation 'io.quarkus:quarkus-mailer'
    implementation 'io.quarkus:quarkus-oidc'
    implementation 'io.quarkus:quarkus-resteasy'
    implementation 'io.quarkus:quarkus-resteasy-jsonb'
    implementation 'io.quarkus:quarkus-resteasy-qute'
    implementation 'io.quarkus:quarkus-scheduler'
    implementation 'io.quarkus:quarkus-smallrye-jwt'

    //implementation 'io.quarkus:quarkus-elytron-security'
    //implementation 'io.quarkus:quarkus-elytron-security-jdbc'
    //implementation 'io.quarkus:quarkus-elytron-security-oauth2'
    //implementation 'io.quarkus:quarkus-keycloak-authorization'
    //implementation 'io.quarkus:quarkus-quartz'
    //implementation 'io.quarkus:quarkus-smallrye-fault-tolerance'
    //implementation 'io.quarkus:quarkus-smallrye-health'
    //implementation 'io.quarkus:quarkus-smallrye-metrics'
    //implementation 'io.quarkus:quarkus-smallrye-openapi'

    //implementation 'jakarta.transaction:jakarta.transaction-api'
    //implementation 'org.jboss.spec.javax.xml.bind:jboss-jaxb-api_2.3_spec'
    //implementation 'jakarta.persistence:jakarta.persistence-api'

    implementation "org.bitbucket.b_c:jose4j"

    implementation 'org.mapstruct:mapstruct'
    compileOnly 'org.mapstruct:mapstruct-processor'

    compileOnly 'com.google.code.findbugs:jsr305'

    implementation 'com.vladmihalcea:hibernate-types-52'

    implementation "jakarta.security.jacc:jakarta.security.jacc-api"
    implementation "net.java.dev.jna:jna"

    testImplementation 'io.quarkus:quarkus-junit5'
    testImplementation 'io.rest-assured:rest-assured'

    implementation 'org.jsoup:jsoup:1.12.1'

    constraints {
        implementation "com.vladmihalcea:hibernate-types-52:${hibernateTypesVersion}"
        implementation "org.mapstruct:mapstruct:${mapstructVersion}"
        compileOnly "org.mapstruct:mapstruct-processor:${mapstructVersion}"
        compileOnly "com.google.code.findbugs:jsr305:${findbugsJsr305Version}"
        implementation "jakarta.security.jacc:jakarta.security.jacc-api:${jakartaJaccVersion}"
        implementation "net.java.dev.jna:jna:${jnaVersion}"
        implementation "org.bitbucket.b_c:jose4j:${jose4jVersion}"
    }
}

spotless {
  java {
    googleJavaFormat()
    removeUnusedImports()
  }
}

group "eu.mulk"
version "${projectVersion}"

task yarnInstall(type:Exec) {
  def resourceDir = "src/main/resources/META-INF/resources"

  inputs.file "${resourceDir}/package.json"
  outputs.dir "${resourceDir}/node_modules"
  outputs.file "${resourceDir}/yarn.lock"

  workingDir resourceDir
  commandLine "yarn", "install"
}

task snowpack(type:Exec) {
  def resourceDir = "src/main/resources/META-INF/resources"

  dependsOn yarnInstall

  inputs.dir "${resourceDir}/node_modules"
  inputs.file "${resourceDir}/yarn.lock"
  inputs.file "${resourceDir}/package.json"
  outputs.dir "${resourceDir}/web_modules"

  workingDir resourceDir
  commandLine "yarn", "run", "snowpack"
}

task compileWeb {
  dependsOn snowpack

  doLast {}
}

processResources {
    exclude("META-INF/resources/node_modules/**/*")
    exclude("META-INF/resources/package.json")
    exclude("META-INF/resources/yarn.lock")
}

quarkusBuild.dependsOn compileWeb

task buildDocker(type: DockerBuildImage) {
    inputDir = file(".")
    dockerFile = file("src/main/docker/Dockerfile.jvm")
    images.add("docker.benkard.de/mulk/mulkcms2:${projectVersion}")
}

buildDocker.dependsOn quarkusBuild
assemble.dependsOn buildDocker

task pushDocker(type: DockerPushImage) {
    images.add("docker.benkard.de/mulk/mulkcms2:${projectVersion}")
}

pushDocker.dependsOn buildDocker
