summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Retter <adam.retter@googlemail.com>2021-01-07 17:11:50 -0800
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>2021-01-07 17:13:19 -0800
commitc22e619f7e0e20b5777bd98995caaf767fbf6103 (patch)
treeb387e7ec65767fb79be196bf6cc1d230fd50ee88
parent48c0843e695c414a91e3d87d2f4d7fd63e1b5b9a (diff)
Store test logs as artifacts if the build fails in CircleCI (#7812)
Summary: If a workflow fails in CircleCI this will ensure that the `t/` directory is tar'd up and added to the workflow as an artifact. This allows us to download the detailed logs and see what went wrong. Pull Request resolved: https://github.com/facebook/rocksdb/pull/7812 Reviewed By: zhichao-cao Differential Revision: D25761003 Pulled By: jay-zhuang fbshipit-source-id: 41cfd16c6385bfcc9fb35fb63df84f97d4b8b80b
-rw-r--r--.circleci/config.yml8
1 files changed, 8 insertions, 0 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index ab309146c..7d76991a8 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -62,6 +62,14 @@ commands:
path: /tmp/test-results
- store_artifacts: # store LOG for debugging if there's any
path: LOG
+ - run: # on fail, compress Test Logs for diagnosing the issue
+ name: Compress Test Logs
+ command: tar -cvzf t.tar.gz t
+ when: on_fail
+ - store_artifacts: # on fail, store Test Logs for diagnosing the issue
+ path: t.tar.gz
+ destination: test_logs
+ when: on_fail
install-clang-10:
steps: