CodeSign error

I am trying to run my build job on my Dedicated CI Machine (iMac) using GitLab CI and Fastlane.

It throws an error while building the app :

** ARCHIVE FAILED **
The following build commands failed:

    CodeSign /var/root/Library/Developer/Xcode/DerivedData/XXXX-bjxxtxqovrbjgodpvbuyaspcfsfb/Build/Intermediates.noindex/ArchiveIntermediates/XXXXX/InstallationBuildProductsLocation/Applications/XXXX.app/Frameworks/Designables.framework (in target 'XXXXX' from project 'XXXXX')

Exit status: 65

Although I have tried unlocking both of my keychains (login and system) and some other things.

I still don’t know why the derived data is getting stored in the root folder which is not accessible for me through finder.

All the certificates and profiles are present in the CI machine and below is my lane which gets executed for this job:

lane :distribute do
        build_ios_app(scheme: "xxxxx", workspace: "xxxxxx.xcworkspace", clean: true, export_method: "development", configuration: "Debug", export_options: {
signingStyle: "manual", compileBitcode: false, provisioningProfiles: { 
      "com.xxxxx" => "xxxxxxxProfile28Sept2022",
      "com.xxx.xxxxNotificationService" => "xxxxxxNotificationService28Sept2022"
    }})