Xcodebuild produces wrong result on ci

My project works fine on local environment but it fails to run on ci. The problem is, I would like to use derived data path to default location, and so configure WorkspaceSettings.xcsettings. But xcodebuild on ci doesn’t produce variables based on this file, which drives me crazy. Any idea how to get this fix?