Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.

Commit a5f10f1

Browse files
authored
Merge pull request #1359 from sudo-suhas/docs-faq-ci-caching
update FAQ CI usage section for caching caveats
2 parents 1bc50f9 + da79333 commit a5f10f1

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

docs/FAQ.md

+23
Original file line numberDiff line numberDiff line change
@@ -467,3 +467,26 @@ before_install:
467467
install:
468468
- dep ensure
469469
```
470+
471+
Caching can also be enabled but there are a couple of caveats you should be aware of:
472+
473+
> Until recently, we have had intermittent cache corruption that would have been super annoying if it was breaking Travis build too.
474+
>
475+
> Also according to https://docs.travis-ci.com/user/caching/#Things-not-to-cache, they don't recommend it for larger caches.
476+
>
477+
> https://docs.travis-ci.com/user/caching/#How-does-the-caching-work%3F
478+
>
479+
> > Note that this makes our cache not network-local, it's still bound to network bandwidth and DNS resolutions for S3.
480+
> > That impacts what you can and should store in the cache. If you store archives larger than a few hundred megabytes in the cache, it's unlikely that you'll see a big speed improvement.
481+
>
482+
> [@carolynvs in #1293](https://github.com/golang/dep/pull/1293#issuecomment-342969292)
483+
484+
If you are sure you want to enable caching on travis, it can be done by adding `$GOPATH/pkg/dep`, the default location for `dep` cache, to the cached directories:
485+
486+
```yml
487+
# ...
488+
489+
cache:
490+
directories:
491+
- $GOPATH/pkg/dep
492+
```

0 commit comments

Comments
 (0)