X509: failed to load system roots and no roots provided while attaching workspace

While attaching workspace, following error occurred and the job was failed.

Downloading workspace layers Error downloading workspace layer for job cd6f3c73-XXXX-XXXX-XXXX-XXXXXXXXXXXX: RequestError: send request failed caused by: Get https://circle-production-customer-artifacts.s3.amazonaws.com/?list-type=2&prefix=picard%!F(MISSING)forks%!F(MISSING)5342XXXXXXXXXXXXXXXXXXXX%!F(MISSING)6XXXXXX%!F(MISSING)unknown%!F(MISSING)unknown%!F(MISSING)workflows%!F(MISSING)workspaces%!F(MISSING)fcac2c62-XXXX-XXXX-XXXX-XXXXXXXXXXXX%!F(MISSING)0%!F(MISSING)cd6f3c73-XXXX-XXXX-XXXX-XXXXXXXXXXXX: x509: failed to load system roots and roots provided

In .circleci/config.yml, workspace was made by:

  root: .
    - output

Then in next job, workspace is attempted to attach by:

  at: .

Is it a CircleCI bug?

Hi @halfer,

Thank you for your feedback. I updated the snippets.

Hmm, odd. Looks like a bug. Are you using the Docker executor, and are you using version 2.0 or 2.1 of the config schema?

Yes. I’m using the Docker executor on CircleCI 2.0.

The full .circleci/config.yml is found here.

Hmm, OK - try using absolute paths for root and/or at?

Are the MISSING and unknown things in your URL obfuscations you have made, or is that the actual URL?

The URL in my first message is “as is” from Job page but except IDs masked with ‘X’ such as 5342XXXXXXXXXXXXXXXXXXXX and 6XXXXXX.

persist_to_workspace.root can understand relative paths as described in https://circleci.com/docs/2.0/configuration-reference/#persist_to_workspace. Actually the above usage of persist_to_workspace and attach_workspace are identical with my another project and it runs successfully.

Sure, but if you are stuck, try it anyway. It might help, and getting unstuck is helpful, even if there is still a bug to report.

Using absolute paths did not resolve the issue, but I can finally avoid this issue by replacing debian:stretch with CircleCI official docker image.

Thank you @halfer a lot for advising me.

1 Like