{"componentChunkName":"component---src-templates-post-template-js","path":"/travis-error-job-exceeded-maximum-log-length","result":{"data":{"markdownRemark":{"id":"2e513b9d-cf6b-5209-b9e7-74431122e5e1","html":"<p>My project is working fine until this morning, Travis CI suddenly complained about the length of the log. I’m not sure what happened, but a commit from last week also produces an error now.</p>\n<p>In my case, my app uploads around 10K+ pages in S3, so I need to tell aws-cli, “Hey! don’t log any uploaded files. Okay?“. I just need to add  the “—quiet” parameter to do this.</p>\n<p>So the script now looked like this :</p>\n<div class=\"gatsby-highlight\" data-language=\"text\"><pre class=\"language-text\"><code class=\"language-text\"> aws s3 sync public s3://$BUCKET_NAME --region=$BUCKET_REGION --delete --quiet</code></pre></div>\n<p>If you push your code now, it will still get an error. Keep reading down below :D</p>\n<p>You will get an error now because Travis CI will complain again regarding no activity or output from the logs. So you need to tell Travis CI to just fucking please wait for my upload to finish.</p>\n<p>Luckily, I found this neat little tool “travis-wait-improved”</p>\n<p>Here’s how I used it on my project.</p>\n<div class=\"gatsby-highlight\" data-language=\"text\"><pre class=\"language-text\"><code class=\"language-text\">before_deploy: \n  - imagine code here\n  - pip install awscli \n  - pip install travis-wait-improved \n  - imagine more code\ndeploy: \n provider: script  \n script: travis-wait-improved --timeout 20m aws s3 sync public s3://$BUCKET_NAME --region=$BUCKET_REGION --delete --quiet</code></pre></div>\n<p>Now your build should work perfectly, if not please don’t hesitate to contact me :)</p>","fields":{"slug":"travis-error-job-exceeded-maximum-log-length","tagSlugs":["/tag/travis-ci/"]},"frontmatter":{"date":"2019-11-05T13:01:58.952Z","description":"How to fix the \"The job exceeded the maximum log length, and has been terminated\"","tags":["travis-ci"],"title":"TRAVIS CI error: The job exceeded the maximum log length, and has been terminated."}}},"pageContext":{"slug":"travis-error-job-exceeded-maximum-log-length"}},"staticQueryHashes":["251939775","401334301","4072520377"]}