@@LambdaTest Bro you left us hanging as to how did you configure your server to receive webhook request at /github-webhook. Could you please point to the tutorial where you build this endpoint?
Thank you so much for your amazing feedback! 😊 Thrilled to hear that the video was so helpful. Your support means a lot-glad to be part of your journey!
It worked! :), I've downgraded the Jenkins and used the same version you were using in this tutorial. I was using the latest Jenkins version 2.332.1, will dig around this issue to get it solved and will post the findings if any. Thanks!!
I have a question if we are using Selenium can we execute the script and if yes can you please provide guideline how can we do that. One more question is AWS EC2 with public IP address is available free?
@@LambdaTest already subscribed 😊 You are the first and only youtuber who explains how to set up Jenkins-Github connection without any gap... Congrats !❤
Thanks for this very informative tutorial. But there is one question left in my mind: why do i need access tokens and ssh keys when using jenkins with github? Shouldn't both access methods do the same thing, which is communicating with GitHub. Why are both methods necessary?
Hey there 👋🏻 Access tokens are used to authenticate Jenkins with the GitHub API, while SSH keys are used for authenticating the Jenkins server with GitHub repositories over SSH. Both methods serve different purposes and are necessary for allowing Jenkins to interact with GitHub in different ways while providing a secure and efficient way to automate workflows.
Hey there, When integrating a private repo with Jenkins: 1. Generate SSH Key: - In Jenkins server terminal, use ssh-keygen to create an SSH key. - Save the generated key, usually in ~/.ssh/id_rsa. 2. Add SSH Key to GitHub: - Go to your GitHub account settings. - Navigate to "SSH and GPG keys" and click "New SSH key". - Copy the public key from ~/.ssh/id_rsa.pub on Jenkins server and paste it into GitHub. 3. Configure Jenkins: - In Jenkins, go to "Manage Jenkins" > "Manage Credentials" > "(global)". - Add a new SSH Username with private key. Use the default id_rsa for the key. 4. Job Configuration: - When creating or configuring a Jenkins job, under "Source Code Management", select "Git". - For "Repository URL", use the SSH URL of your private repo (e.g., git@github.com:username/repo.git). - Select the added credentials from the drop-down. 5. Ensure Connection: - Test the connection to ensure Jenkins can access the private repository.
I don't believe it is possible to follow along without a Jenkins instance that doesn't have some public access point. You would need an on-premise Enterprise version of GitHub inside of your network to follow along with a Jenkins instance that doesn't have a public access point. GitHub Enterprise Cloud version may have a feature to allow connections to a corporate/private network but if so I am not aware of it.
Hi Clemens, both are used to authenticate the GitHub account. We have used here personal access token to verify if Jenkins is reachable with the GitHub APIs and used ssh-key to clone the private repository for the CI/CD pipeline.
In this video, we are using an AWS EC2 instance. When you run an EC2 instance with a dynamic IP it will automatically generate an IP and I think the hostname is automatically concatenated with the IP. This EC2 instance is available on the public internet as well. If you wanted a custom domain name for your Jenkins instance, I think you would need to configure a DNS server on your local network so that you could create a domain name like "my-jenkins-instance.com:8080/". If you were to configure DNS for an EC2 instance on AWS, I believe you would want to use the Route 53 AWS service. Hope it helps!
3 года назад+2
Hello, A solution could be to use a free webhook proxy server. (SocketXP, LocalXpose etc.) Hope it helps. Great tutorials on this channel. Thanks
Hi, could you help me please? I've been trying to connect my AWs intance as you did, but always shows me an error, about No ED25519 or ecdsa, i created a new ssh (ecdsa and ED25519), but it doesn't work, add githubt to kwnos host neither, even I created a new aws intance, do you have any idea what happends there? or what can I do to solve?
Hey Rubi 👋🏻 Can you please try runing the following command on the Jenkins server, as the Jenkins user, to get a proper known_hosts file. ssh -T git@github.com After this, restart Jenkins and it will work. Please let us know if this helps
Hi, Need help on Jenkins build trigger. In a github repository there is a specific file called details.txt, if any change is done in details.txt the jenkins job need to be triggered... Note: Only when there is any change in details.txt it need to be triggered not when something else is changed. How can we resolve this?
Hey there 👋🏻 Although we have configured Jenkins to communicate with our repository on GitHub, we still have to manually start the build from Jenkins. To automatically run builds, Jenkins listens for POST requests at a Hook URL. We need to give this URL to the repository on GitHub. Then, whenever code is pushed to that repository, GitHub will send a POST request to the Hook URL and Jenkins will run the build.
Best tutorial I have ever come across. Thank You so much
Thanks Basam
@@LambdaTest Bro you left us hanging as to how did you configure your server to receive webhook request at /github-webhook.
Could you please point to the tutorial where you build this endpoint?
absolute best video I've ever followed. Not one of these things failed. I was able to follow through so smooth!!! thank you !!
Thank you so much for your amazing feedback! 😊 Thrilled to hear that the video was so helpful. Your support means a lot-glad to be part of your journey!
I was struggling to find best answer in Google until I saw your video. I made my Jinkins works after watching your instructions. Thank you.
Glad it was helpful.
Please subscribe to our RUclips channel for more such videos 🌟
This is the best Jenkins tutorial, super clear and useful, thanks!!
We're delighted that you found it helpful! 😊
Don't forget to subscribe to our channel for the latest updates on upcoming tutorials! ✨
great tutorial - really comprehensive! thank you :)
Glad you found this helpful😊
Subscribe to our channel to never miss an update on the upcoming tutorials! ✨
wow! really great walkthrough! dropped a like and subscribed. thank you!
Thanks for the sub!
It worked! :), I've downgraded the Jenkins and used the same version you were using in this tutorial. I was using the latest Jenkins version 2.332.1, will dig around this issue to get it solved and will post the findings if any. Thanks!!
Glad it helped!
Really good tutorial! You really know you way round Jenkins! 👴
Glad you found this helpful😊
Subscribe to our channel to never miss an update on the upcoming tutorials! ✨
Great tutorial as always.
I have a question if we are using Selenium can we execute the script and if yes can you please provide guideline how can we do that.
One more question is AWS EC2 with public IP address is available free?
Glad you liked it
💯 The Best One... thanks a lot
Glad you liked it!
Subscribe, and look forward to more such tutorials! ✨
@@LambdaTest already subscribed 😊 You are the first and only youtuber who explains how to set up Jenkins-Github connection without any gap... Congrats !❤
Awesome video! Thanks for sharing!
Thanks for watching!
Subscribe, and look forward to more such tutorials! ✨
Thanks for this very informative tutorial. But there is one question left in my mind: why do i need access tokens and ssh keys when using jenkins with github? Shouldn't both access methods do the same thing, which is communicating with GitHub. Why are both methods necessary?
Hey there 👋🏻
Access tokens are used to authenticate Jenkins with the GitHub API, while SSH keys are used for authenticating the Jenkins server with GitHub repositories over SSH. Both methods serve different purposes and are necessary for allowing Jenkins to interact with GitHub in different ways while providing a secure and efficient way to automate workflows.
How would you go about it if you are trying to connect a private repo?
Hey there,
When integrating a private repo with Jenkins:
1. Generate SSH Key:
- In Jenkins server terminal, use ssh-keygen to create an SSH key.
- Save the generated key, usually in ~/.ssh/id_rsa.
2. Add SSH Key to GitHub:
- Go to your GitHub account settings.
- Navigate to "SSH and GPG keys" and click "New SSH key".
- Copy the public key from ~/.ssh/id_rsa.pub on Jenkins server and paste it into GitHub.
3. Configure Jenkins:
- In Jenkins, go to "Manage Jenkins" > "Manage Credentials" > "(global)".
- Add a new SSH Username with private key. Use the default id_rsa for the key.
4. Job Configuration:
- When creating or configuring a Jenkins job, under "Source Code Management", select "Git".
- For "Repository URL", use the SSH URL of your private repo (e.g., git@github.com:username/repo.git).
- Select the added credentials from the drop-down.
5. Ensure Connection:
- Test the connection to ensure Jenkins can access the private repository.
Hi, thanks for the detailed videos, very useful. Is there a way to follow along without a public Jenkins instance?
I don't believe it is possible to follow along without a Jenkins instance that doesn't have some public access point. You would need an on-premise Enterprise version of GitHub inside of your network to follow along with a Jenkins instance that doesn't have a public access point. GitHub Enterprise Cloud version may have a feature to allow connections to a corporate/private network but if so I am not aware of it.
Can you do a video where build is triggered when you send a PR from specific branches,. I tried using wild card but it did not work
Absolutely, we'll definitely address that soon.
Thank you!
Glad the video was helpful!
Please subscribe the channel for more such videos🙂
Why do we need both a personal access token and an SSH key? Aren't both used to authenticate with GitHub?
Hi Clemens, both are used to authenticate the GitHub account. We have used here personal access token to verify if Jenkins is reachable with the GitHub APIs and used ssh-key to clone the private repository for the CI/CD pipeline.
Thank you for the great tutorial :),
how do I set a base Jenkins URL like you have in 18:45 ? It still shows I'm on localhost
In this video, we are using an AWS EC2 instance. When you run an EC2 instance with a dynamic IP it will automatically generate an IP and I think the hostname is automatically concatenated with the IP. This EC2 instance is available on the public internet as well. If you wanted a custom domain name for your Jenkins instance, I think you would need to configure a DNS server on your local network so that you could create a domain name like "my-jenkins-instance.com:8080/". If you were to configure DNS for an EC2 instance on AWS, I believe you would want to use the Route 53 AWS service.
Hope it helps!
Hello, A solution could be to use a free webhook proxy server. (SocketXP, LocalXpose etc.)
Hope it helps.
Great tutorials on this channel.
Thanks
@ Thanks
@@LambdaTest How can you suddenly switch to AWS EC2 from localhost, very difficult to follow the tutorial...
Hi, could you help me please? I've been trying to connect my AWs intance as you did, but always shows me an error, about No ED25519 or ecdsa, i created a new ssh (ecdsa and ED25519), but it doesn't work, add githubt to kwnos host neither, even I created a new aws intance, do you have any idea what happends there? or what can I do to solve?
Hey Rubi 👋🏻
Can you please try runing the following command on the Jenkins server, as the Jenkins user, to get a proper known_hosts file.
ssh -T git@github.com
After this, restart Jenkins and it will work.
Please let us know if this helps
Hi, Need help on Jenkins build trigger. In a github repository there is a specific file called details.txt, if any change is done in details.txt the jenkins job need to be triggered... Note: Only when there is any change in details.txt it need to be triggered not when something else is changed. How can we resolve this?
Hey there 👋🏻
Although we have configured Jenkins to communicate with our repository on GitHub, we still have to manually start the build from Jenkins. To automatically run builds, Jenkins listens for POST requests at a Hook URL. We need to give this URL to the repository on GitHub. Then, whenever code is pushed to that repository, GitHub will send a POST request to the Hook URL and Jenkins will run the build.
super like 👍
Glad you liked it!
Please subscribe to the channel for more such videos🌟