<p>One of the headaches of <code>.yml</code> files is the indentation. So the parse error I was getting in the Request tab was saying no newline added. I was not clear whether that meant it needed a new line or was missing a new line, but by running: <code>wc -l .travis.yml</code> I was able to detect that it was not outputting the correct number of lines.</p>

<p>I tried about five different ways to format the <code>.yml</code> file allowing it to keep me focused towards the end of the files line number where the error was pointing towards.</p>

<p>I happen to look up and realized the beginning of the deploy: script was not properly aligned, so I adjusted with a shift+tab and after I got it properly aligned, TravisCI recognized my changes and properly ran the script and successfully deployed the application to Elasticbeanstalk.</p>

CC BY-SA 4.0
2019-02-22T09:27:01.570Z
Try adding `yamllint` to your git workflow, so before committing an unparsable yaml file you can validate it. I end up adding this to my git-hook scripts.
Hashfyre
CC BY-SA 4.0
2019-02-22T15:01:44.147Z
@Hashfyre, thank you for the tip. I am going to look into that today.
Daniel
CC BY-SA 4.0
2019-02-21T22:49:13.430Z
2019-02-21T22:49:13.430Z
Daniel
<p>I added some AWS keys to my <code>.travis.yml</code> file so that it would deploy my application over to ElasticBeanstalk, but after I committed the changes to the file and pushed to master, nothing happened.</p>

<p>I thought perhaps I needed to restart build. This added my AWS keys, but no installation of deployment dependencies as I had expected and no deployment to AWS.</p>

<p>Not sure what happened here. Did I not wait long enough for TravisCI to start the new build?</p>

<p>This is my <code>.travis.yml</code> file:</p>

<pre><code>sudo: required
services:
  - docker

before_install:
  - docker build -t danale/project-name -f Dockerfile.dev .

script:
  - docker run danale/project-name npm run test -- --coverage

  deploy:
    provider: elasticbeanstalk
    region: "us-east-1"
    app: "project-name"
    env: "ProjectName-env"
    bucket_name: "elasticbeanstalk-us-east-1-123456789"
    bucket_path: "project-name"
    on:
      branch: master
    access_key_id: $AWS_ACCESS_KEY
    secret_access_key: 
      secure: "$AWS_SECRET_KEY"
</code></pre>

<p>I conducted a <code>git add . &amp;&amp; git commit -m "added travis deploy script" &amp;&amp; git push origin master</code></p>

<p>No deployment afterwards. I don't see where I missed a step here:
<a href="https://docs.travis-ci.com/user/deployment/elasticbeanstalk/" rel="nofollow noreferrer">https://docs.travis-ci.com/user/deployment/elasticbeanstalk/</a></p>

<amazon-web-services><git><github><travis-ci>
TravisCI did not run after adding more configuration to .travis.yml file
Daniel
# TravisCI did not run after adding more configuration to .travis.yml file

(Asked by: username_0 on 2019-02-21)

I added some AWS keys to my .travis.yml file so that it would deploy my application over to ElasticBeanstalk, but after I committed the changes to the file and pushed to master, nothing happened.
I thought perhaps I needed to restart build. This added my AWS keys, but no installation of deployment dependencies as I had expected and no deployment to AWS.
Not sure what happened here. Did I not wait long enough for TravisCI to start the new build?
This is my .travis.yml file:
sudo: required
services:
  - docker

before_install:
  - docker build -t danale/project-name -f Dockerfile.dev .

script:
  - docker run danale/project-name npm run test -- --coverage

  deploy:
    provider: elasticbeanstalk
    region: "us-east-1"
    app: "project-name"
    env: "ProjectName-env"
    bucket_name: "elasticbeanstalk-us-east-1-123456789"
    bucket_path: "project-name"
    on:
      branch: master
    access_key_id: $AWS_ACCESS_KEY
    secret_access_key: 
      secure: "$AWS_SECRET_KEY"

I conducted a git add . && git commit -m "added travis deploy script" && git push origin master
No deployment afterwards. I don't see where I missed a step here:
https://docs.travis-ci.com/user/deployment/elasticbeanstalk/

**Tags:** amazon-web-services, git, github, travis-ci


---

## 1 answers

### Answer by username_0 on 2019-02-21. Score: 1 | Accepted answer

One of the headaches of `.yml` files is the indentation. So the parse error I was getting in the Request tab was saying no newline added. I was not clear whether that meant it needed a new line or was missing a new line, but by running: `wc -l .travis.yml` I was able to detect that it was not outputting the correct number of lines.

I tried about five different ways to format the `.yml` file allowing it to keep me focused towards the end of the files line number where the error was pointing towards.

I happen to look up and realized the beginning of the deploy: script was not properly aligned, so I adjusted with a shift+tab and after I got it properly aligned, TravisCI recognized my changes and properly ran the script and successfully deployed the application to Elasticbeanstalk.

> **Comments:**
> **username_1**: Try adding `yamllint` to your git workflow, so before committing an unparsable yaml file you can validate it. I end up adding this to my git-hook scripts.  
> **username_0**: @username_1, thank you for the tip. I am going to look into that today.  

---

