28 lines
734 B
Kotlin
28 lines
734 B
Kotlin
import circlet.pipelines.script.put
|
|
|
|
job("Deploy") {
|
|
startOn {
|
|
gitPush { enabled = false }
|
|
}
|
|
|
|
container(image = "openjdk:11") {
|
|
kotlinScript { api ->
|
|
api.gradlew("installDist")
|
|
api.fileShare().put(java.io.File("build/install"))
|
|
}
|
|
}
|
|
|
|
container(image = "openjdk:11") {
|
|
env["HOST"] = Params("spc-host")
|
|
env["USER"] = Secrets("spc-webmaster-user")
|
|
env["ID"] = Secrets("spc-webmaster-id")
|
|
|
|
shellScript {
|
|
interpreter = "/bin/bash"
|
|
content = """
|
|
echo ${'$'}ID > id.pub
|
|
scp -r -i id.pub /mnt/space/share/spc-site/ "${'$'}USER@${'$'}HOST:/opt"
|
|
""".trimIndent()
|
|
}
|
|
}
|
|
} |