ci: improve conveyor setup

This commit is contained in:
zaneschepke
2026-02-27 11:26:46 -05:00
parent a59bfeaa74
commit 1b83cd4f0f
6 changed files with 28 additions and 20 deletions
+1
View File
@@ -19,3 +19,4 @@ captures
**/xcshareddata/WorkspaceSettings.xcsettings **/xcshareddata/WorkspaceSettings.xcsettings
node_modules/ node_modules/
composeApp/generated.conveyor.conf composeApp/generated.conveyor.conf
local-site
+1 -1
View File
@@ -62,7 +62,7 @@ subprojects {
registerConveyorTask("buildLinuxDeb", "debian-package", "deb") registerConveyorTask("buildLinuxDeb", "debian-package", "deb")
registerConveyorTask("buildWindowsMsix", "windows-msix", "windows") registerConveyorTask("buildWindowsMsix", "windows-msix", "windows")
registerConveyorTask("buildConveyorSite", "site", "site") registerConveyorTask("buildConveyorSite", "copied-site", "site")
registerConveyorTask("buildLinuxDebRelease", "debian-package", "deb", "conveyor-release.conf") registerConveyorTask("buildLinuxDebRelease", "debian-package", "deb", "conveyor-release.conf")
+11 -14
View File
@@ -6,14 +6,21 @@ fun Project.registerConveyorTask(
taskName: String, taskName: String,
packageType: String, packageType: String,
subDir: String, subDir: String,
configFile: String = "conveyor.conf", configFile: String = "conveyor-local.conf",
signingKeyEnv: String? = null,
) { ) {
tasks.register<Exec>(taskName) { tasks.register<Exec>(taskName) {
group = "distribution" group = "distribution"
val outputDir = layout.buildDirectory.dir("conveyor/$subDir") val outputDir = layout.buildDirectory.dir("conveyor/$subDir")
outputs.dir(outputDir) outputs.dir(outputDir)
(System.getenv("CONVEYOR_SIGNING_KEY") ?: LocalProperties.get("conveyor.signing-key"))?.let {
environment("CONVEYOR_SIGNING_KEY", it)
}
(System.getenv("CONVEYOR_PAT") ?: LocalProperties.get("github.pat"))?.let {
environment("CONVEYOR_PAT", it)
}
val args = val args =
mutableListOf( mutableListOf(
"conveyor", "conveyor",
@@ -23,21 +30,11 @@ fun Project.registerConveyorTask(
"--output-dir", "--output-dir",
outputDir.get().asFile.absolutePath, outputDir.get().asFile.absolutePath,
packageType, packageType,
"--rerun=all"
) )
if (signingKeyEnv == null) { LocalProperties.get("conveyor.passphrase")?.let {
// dev builds use passphrase environment("CONVEYOR_PASSPHRASE", it)
environment(
"CONVEYOR_PASSPHRASE",
System.getenv("CONVEYOR_PASSPHRASE")
?: LocalProperties.get("conveyor.passphrase")
?: "",
)
args.add(1, "--passphrase=env:CONVEYOR_PASSPHRASE") args.add(1, "--passphrase=env:CONVEYOR_PASSPHRASE")
} else {
// release builds use raw signing key
environment("CONVEYOR_SIGNING_KEY", System.getenv(signingKeyEnv) ?: "")
} }
commandLine(args) commandLine(args)
+9
View File
@@ -0,0 +1,9 @@
include required("conveyor.conf")
app {
site {
copy-to = "./local-site"
base-url = "http://localhost"
consistency-checks = "warn"
}
}
+6 -4
View File
@@ -4,12 +4,14 @@ conveyor.billing-email = "dev@zaneschepke.com"
app { app {
signing-key = ${env.CONVEYOR_SIGNING_KEY} // TODO for when we get CI working
mac.certificate = apple.cer // signing-key = ${env.CONVEYOR_SIGNING_KEY}
windows.certificate = windows.cer // mac.certificate = apple.cer
// windows.certificate = windows.cer
site { site {
copy-to = "/site" copy-to = "./site"
consistency-checks = "warn"
// will overwrite base-url // will overwrite base-url
github { github {
oauth-token = ${env.CONVEYOR_PAT} oauth-token = ${env.CONVEYOR_PAT}
-1
View File
@@ -15,7 +15,6 @@ app {
site { site {
display-name = "WG Tunnel" display-name = "WG Tunnel"
base-url = "http://localhost"
show-conveyor-badge = true show-conveyor-badge = true
theme = "dark" theme = "dark"