Thoughtworks Go - dreaded 404 on artifact fetching
I've run into this more than I'd care to admit, so figured I should post it up.
Often when chaining Go pipelines I run into a message like:
I've found there are two reasons for this message to come up.
What you SHOULD see is:
A subtle but important difference. The source dir MUST match your build artifact location. In this example, the build artifact looks like:
For the latter example, it's pretty obvious wha happen.
Check here on your Go server:
/var/lib/go-server/artifacts/pipelines/DevelopmentCI-Build/744/ExtractCIcomponents/1/ExtractZip/components/web/
If you no see files n junk...it's been purged. But there is a way out!!
To regen the files, simply re-run the build from that original pipeline run - the files will re-appear, and any call to 'latest' for that pipeline run will be re-populated. (although the one time this came up, the code piece built, but the tests piece did not) It was enough to get us past the production deployment - we could then say 'hay hay hay give Go more disk!'.
Often when chaining Go pipelines I run into a message like:
- Artifact path specified incorrectly
- Go server purging accidentally removed the file
An example bad artifact path is visible in the example above. If you check the pipeline details, you see:
- Pipeline Name: #{fetchPipeline}
- Stage Name: ExtractCIcomponents
- Job Name: ExtractZIP
- Source Directory: components/WebPortal
- Destination: components
What you SHOULD see is:
- Pipeline Name: #{fetchPipeline}
- Stage Name: ExtractCIcomponents
- Job Name: ExtractZIP
- Source Directory: components/web/WebPortal
- Destination: components
A subtle but important difference. The source dir MUST match your build artifact location. In this example, the build artifact looks like:
Source: components/web/WebPortal
Destination: components/web
Check here on your Go server:
/var/lib/go-server/artifacts/pipelines/DevelopmentCI-Build/744/ExtractCIcomponents/1/ExtractZip/components/web/
If you no see files n junk...it's been purged. But there is a way out!!
To regen the files, simply re-run the build from that original pipeline run - the files will re-appear, and any call to 'latest' for that pipeline run will be re-populated. (although the one time this came up, the code piece built, but the tests piece did not) It was enough to get us past the production deployment - we could then say 'hay hay hay give Go more disk!'.
Comments
Post a Comment