forked from mirrors/0ad
Fix Jenkins pipelines on Linux agent
The Linux agent now runs Docker in rootless mode for additional security. Operations inside containers must be run as root to match the underprivileged user running Docker.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 2024 Wildfire Games.
|
||||
/* Copyright (C) 2025 Wildfire Games.
|
||||
* This file is part of 0 A.D.
|
||||
*
|
||||
* 0 A.D. is free software: you can redistribute it and/or modify
|
||||
@@ -57,6 +57,9 @@ pipeline {
|
||||
customWorkspace "workspace/${JENKINS_COMPILER}-pch"
|
||||
dir 'build/jenkins/dockerfiles'
|
||||
filename "${JENKINS_COMPILER}.Dockerfile"
|
||||
// Prevent Jenkins from running commands with the UID of the host's jenkins user
|
||||
// https://stackoverflow.com/a/42822143
|
||||
args '-u root'
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user