mirror of
https://github.com/wgtunnel/desktop.git
synced 2026-06-02 00:29:09 +02:00
ci: improve conveyor setup
This commit is contained in:
@@ -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
@@ -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")
|
||||||
|
|||||||
@@ -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)
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
include required("conveyor.conf")
|
||||||
|
|
||||||
|
app {
|
||||||
|
site {
|
||||||
|
copy-to = "./local-site"
|
||||||
|
base-url = "http://localhost"
|
||||||
|
consistency-checks = "warn"
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -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}
|
||||||
|
|||||||
@@ -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"
|
||||||
|
|||||||
Reference in New Issue
Block a user