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.
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.
So the script now looked like this :
aws s3 sync public s3://$BUCKET_NAME --region=$BUCKET_REGION --delete --quietIf you push your code now, it will still get an error. Keep reading down below :D
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.
Luckily, I found this neat little tool “travis-wait-improved”
Here’s how I used it on my project.
before_deploy:
- imagine code here
- pip install awscli
- pip install travis-wait-improved
- imagine more code
deploy:
provider: script
script: travis-wait-improved --timeout 20m aws s3 sync public s3://$BUCKET_NAME --region=$BUCKET_REGION --delete --quietNow your build should work perfectly, if not please don’t hesitate to contact me :)