Nice explanation, You covered the online tutorial gap, There is very less video on ci/cd with proper guide. you did it well, make more video on github, docker, aws,and jenkins, how this technology work togher, how to use this all in one project, this is the gap that no one is covering in theri tutoirals
Best tutorial, Top notch explanation, understandable. The exact tutorial that covers all the topics that a beginner could understand. Thank you very much for your effort
Hey, I really like your content. Very informative. Could you perhaps do a video on deploying an angular application with ssr, using github actions, docker, github container registry and deploying it to aws ?
@@IntegrationNinjas Thanks, would be greatly appreciated! I guess a more common route would be to use the ECR of Aws for images, but im interested to see how it would work with github container registries :)
I appreciate the content. But it has some missing concepts like building docker images for different environments. I as a devops professional feels targeting different environments is something which you must cover. Just an idea 😊😊
Hey dude, nice vid! What do you suggest to handle the .env file? My project doesn't run because my ec2 machine doesn't have access to my .env file (cause it's secret, and cannot be in the remote repo). How could i handle it?
I would suggest to add .env details in github repository secret variables. Otherwise you can store these information in vault also, if your runner is running on ec2 then you can access those information from vault.
@@IntegrationNinjas adding .env details on github secrets will not work on ec2 containers as per the process you have shown. I have already try it by myself. We must have to add .env to dockerignore for best practices, we can't build images which includes our env secrets and push it to dockerhub. Which you did not even show us. Just don't write down anything before checking it by yourself, and make videos with complete information.
That's correct, we need to change the strategy here in real time projects. We can go with manual workflow dispatch, scheduled deployments and deployment on merge to a specific branch. We can define a use case and accordingly we can decide the right strategy. Please refer: docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/triggering-a-workflow
Sir kindly make a video how to create a docker customer image and add github actions to that and accessing our project in github codespaces it will definitely reduce many developer's job . I meant developers can work fastly
Nice to hear feedback, steps to create docker image are already there. And will soon start with GitHub Codespaces as well. And if you can more elaborate your query, it will be good.
You can store environment variable details in GitHub secrets and then you can access those variables in your workflow. While building docker image you need to pass build arguments and set them in docker file. Ex: docker build -t your-image-name --build-arg API_KEY=${{ secrets.API_KEY }} . While in docker file you can set these as: # Dockerfile FROM node:14 # Set environment variable ARG API_KEY ENV API_KEY=$API_KEY # Other Dockerfile instructions
It probably depends on your network connection, Firewall or proxy blocking Docker traffic, Registry congestion, Local disk performance. Try out above options if it doesn’t work try updating your docker version or use another tool to pull images from docker.
You can create it on run time as well like below: - name: Create .env file run: echo "MONGO_PASSWORD=${{ secrets.MONGO_PASSWORD }}" >> .env && echo "SITE_URL=${{ secrets.SITE_URL }}" >> .env Store secrets in GitHub secrets.
GitHub Actions is a newer tool that is tightly integrated with GitHub. This means that you can use GitHub Actions to automate your workflows directly from your GitHub repository. GitHub Actions also uses a YAML-based syntax for creating workflows, which is more concise and easier to read than the syntax used by Jenkins.
There might be many reasons. By default, GitHub Actions runners have an idle timeout. If the runner remains idle for a certain period, it can automatically go offline to save resources. You can configure the runner to run as a service to avoid this issue. Follow the below steps as mentioned in the documentation: docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/configuring-the-self-hosted-runner-application-as-a-service Make sure your AWS EC2 instance is up and running.
*Mar 13 2024
Runner name must be 'self-hosted' on deploy > runs-on property.
For me, [aws-ec2] didn't work but 'runs-on: selft-hosted' worked.
I won’t deny this. I also observed the same behaviour recently and seems like this is changed in recent GitHub releases.
Thank you for this awesome video.
I successfully deploy nodejs to ec2.
Glad it helped!
Thanks for sharing this , was looking for it .
Very helpful.
This has really good explaination ! waiting fro the next one on the github action front
Glad it was helpful!
Nice explanation, You covered the online tutorial gap, There is very less video on ci/cd with proper guide. you did it well, make more video on github, docker, aws,and jenkins, how this technology work togher, how to use this all in one project, this is the gap that no one is covering in theri tutoirals
Thanks for your valuable feedback, i will definitely try.
Exact tutorial I was looking for on GitHub actions and deploying nodejs app on ec2. many thanks
Glad it was helpful!
Very helping video this the exact tutorial that I was looking for
Glad to hear it!
This is the exact tutorial I was looking for!
Thank you so much for sharing your experience with the community.
New sub!
Glad it was helpful!
Great video.. you explanation was awesome!
Glad that it was helpful.
Nice explanation brother. Keep up the good work.😍
Thank you 🙂
Best tutorial, Top notch explanation, understandable. The exact tutorial that covers all the topics that a beginner could understand. Thank you very much for your effort
Glad it was helpful! And this motivates me a lot to perform my best.
Thank you so much! That is really helpful!
Glad it was helpful!
Hey, I really like your content. Very informative. Could you perhaps do a video on deploying an angular application with ssr, using github actions, docker, github container registry and deploying it to aws ?
Thanks and great suggestion! I will look into that.
@@IntegrationNinjas Thanks, would be greatly appreciated! I guess a more common route would be to use the ECR of Aws for images, but im interested to see how it would work with github container registries :)
Nice video 👍
Thanks
Saludos amigo, me pareció excelente el contenido, muchas Gracias
Me alegro de que haya sido útil.
This helped me
Thanks for your kind feedback
Good video 👍
Glad it helped!
@@IntegrationNinjas yes!
I appreciate the content. But it has some missing concepts like building docker images for different environments. I as a devops professional feels targeting different environments is something which you must cover. Just an idea 😊😊
Hey dude, nice vid! What do you suggest to handle the .env file? My project doesn't run because my ec2 machine doesn't have access to my .env file (cause it's secret, and cannot be in the remote repo). How could i handle it?
I would suggest to add .env details in github repository secret variables. Otherwise you can store these information in vault also, if your runner is running on ec2 then you can access those information from vault.
@@IntegrationNinjas adding .env details on github secrets will not work on ec2 containers as per the process you have shown. I have already try it by myself. We must have to add .env to dockerignore for best practices, we can't build images which includes our env secrets and push it to dockerhub. Which you did not even show us. Just don't write down anything before checking it by yourself, and make videos with complete information.
On push stratergy is good but on demand is much practical if a large numbers of developers are pushing code frequently
That's correct, we need to change the strategy here in real time projects. We can go with manual workflow dispatch, scheduled deployments and deployment on merge to a specific branch. We can define a use case and accordingly we can decide the right strategy. Please refer: docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/triggering-a-workflow
@@IntegrationNinjas u got a new subscriber.. great content 👍
can you also uplode video on react app deployment on aws ec2 and s3 also include ETL
If you want to deploy to react app just you need to update docker file and rest of process remains same, but surely i will create a video on it.
❤❤❤❤
Sir kindly make a video how to create a docker customer image and add github actions to that and accessing our project in github codespaces it will definitely reduce many developer's job . I meant developers can work fastly
Nice to hear feedback, steps to create docker image are already there. And will soon start with GitHub Codespaces as well. And if you can more elaborate your query, it will be good.
How to manage environment variables used in nodejs server. Where to store it ?
You can store environment variable details in GitHub secrets and then you can access those variables in your workflow.
While building docker image you need to pass build arguments and set them in docker file.
Ex: docker build -t your-image-name --build-arg API_KEY=${{ secrets.API_KEY }} .
While in docker file you can set these as:
# Dockerfile
FROM node:14
# Set environment variable
ARG API_KEY
ENV API_KEY=$API_KEY
# Other Dockerfile instructions
@@IntegrationNinjas thank u so much. This video is really helpful. It is exactly what i needed...
Keep Learning.
there's no job in my runner what could be the issue i am using IAM user credentials.
Workflow was triggered or it was showing waiting for runner to pickup job?
my docker pull when deploy take so long time, can u help me
It probably depends on your network connection, Firewall or proxy blocking Docker traffic, Registry congestion, Local disk performance.
Try out above options if it doesn’t work try updating your docker version or use another tool to pull images from docker.
@@IntegrationNinjas thanks so much
You didn't show how .env file will be created in ec2.
You can create it on run time as well like below:
- name: Create .env file
run: echo "MONGO_PASSWORD=${{ secrets.MONGO_PASSWORD }}" >> .env && echo "SITE_URL=${{ secrets.SITE_URL }}" >> .env
Store secrets in GitHub secrets.
Where is a frontend jenkins far better than this but i dont know why companeis using github actions 🤔
GitHub Actions is a newer tool that is tightly integrated with GitHub. This means that you can use GitHub Actions to automate your workflows directly from your GitHub repository. GitHub Actions also uses a YAML-based syntax for creating workflows, which is more concise and easier to read than the syntax used by Jenkins.
Also jenkins can access to your git. But github tools are far superior and debuging failed jobs are preety good with good community support
self-hosted runners goes offline after some days , i have tried by increasing the storage in ec2 also but no way , what are the possible reasons
There might be many reasons.
By default, GitHub Actions runners have an idle timeout. If the runner remains idle for a certain period, it can automatically go offline to save resources. You can configure the runner to run as a service to avoid this issue.
Follow the below steps as mentioned in the documentation:
docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/configuring-the-self-hosted-runner-application-as-a-service
Make sure your AWS EC2 instance is up and running.
hi
Hi
❤❤❤❤❤