-: In the last section, we set up a git repository on GitHub
and our local machine, and then we wired the two together.
We're now gonna start working
on our Travis CI integration with GitHub.
Now, we haven't spoken about Travis CI too much
so lemme give you a very brief overview.
The entire idea of Travis CI is to watch
for any time that you and I push some changes
or some amount of code
to the GitHub project that we just created.
Anytime that we push up some new code
GitHub is essentially gonna tap
on the shoulder of Travis and it's gonna say, Hey
this person just updated their GitHub repository,
there's some new code here
or some new version of their application.
Travis CI will then automatically pull down all of the code
inside of our GitHub repository, and at that point
it essentially gives us the ability to do some work.
Now really the sky is a limit with Travis.
We can do anything
with your code that you can possibly imagine.
We can test your code, we can deploy it.
We could even delete the whole GitHub repository
from Travis if for some crazy reason you wanted to.
Traditionally people use Travis for
either testing their code base or for deployment.
And for us, we're gonna use it for both.
We're gonna first use Travis to test our code
and then once our code comes up green
or once the tests pass successfully
we'll automatically have Travis deploy our application
over to AWS.
So with that in mind, let's start setting up Travis CI.
Fortunately, the setup is really easy
and really straightforward.
To get started, I'm gonna open up a new browser tab
and then I will navigate to Travis-ci.org.
Now once here, you'll notice I'm already signed in.
I'll go ahead and sign out.
You'll probably see a page like this right here.
You can click on either sign in
with GitHub or sign up right in the middle.
So click on either
and then you'll be prompted to authorize Travis CI.
Now this is a page provided by github.com.
Of course, GitHub is using, or excuse me
Travis CI is making use of ooff here.
So you are essentially granting access to all
of your GitHub repositories over to Travis CI.
So I'll scroll down to the bottom and authorize it.
Now, once we go through that, we'll get redirected backward
to the Travis CI dashboard.
As a quick note, if the dashboard looks different from you
that is totally fine.
Very quickly, you might be seeing something that
looks a little bit like this.
Uh, Where's my dashboard?
There we go.
So if you some see something that looks like this
that is totally fine.
Travis CI is going through a little bit of a redesign
right now, and so by the time you watch this video
you might already be seeing the new design.
And if you are, that's totally fine.
Now I'm going to undo that little beta feature.
There we go.
Okay. So the first thing we have
to do here is tell Travis CI
that we wanted to watch the GitHub repo that you
and I just put together.
So up on the right hand side, I'm gonna click
on the profile link.
If you see a green screen
or a green box right here that talks about enabling
Travis CI as a GitHub app
then you need to go ahead and click that green button.
But again, that's kind of a new beta feature
that I don't yet have access to
but it's another thing that Travis CI is going to roll
out at some point.
So if you see little box right here that says
Oh yeah, something, something GitHub app
just go ahead and click on that button.
Once you go through that, you'll then be presented
with a big list of all the different repositories that exist
inside your account.
So we're going to filter this list and find the
docker dash react repository that we just created.
Once you find on the list, we'll then click the little
I don't know, switch right there
by clicking that switch
we're essentially telling Travis CI that anytime
we push new code up to that GitHub repository
we want Travis CI to pull that code
down and do some amount of work on it.
So that's pretty much step one.
Step one is now complete.
We can now click the logo on the top left hand side
and go back to our dashboard where you will now
see a repository listed on the left hand side.
You can click on it and you'll see something like this
something that says No builds for this repository
cuz we have not yet really done anything at all.
Let's take a quick pause right here.
We're gonna come back to the next section
and we'll start talking about how we can customize Travis CI
and tell it to do some amount of work for us.
So quick break and I'll see you in just a minute.