Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 7

Experiment No.

Aim: To pull the image from the docker and run it on the container.

Learning objective: To make students well versed in how to use Subnet , route tables on
AWS.

System requirements: Docker

Theory:
1. Docker

Docker on AWS facilitates the efficient deployment and management of containerized


applications. Leveraging Docker's lightweight, portable containers, developers can
package applications along with their dependencies, ensuring consistency across different
environments. AWS offers a robust infrastructure for hosting Docker containers, with
services like EC2 for virtual server provisioning, ECS for orchestrating containerized
workloads, and ECR for storing and managing Docker images. By utilizing Docker on
AWS, organizations can streamline their development and deployment processes,
improve scalability, and optimize resource utilization, ultimately enhancing agility and
reducing operational overhead

2. Node

Running Node.js applications in Docker provides developers with a flexible and scalable
environment for building and deploying web applications. Docker allows for the
encapsulation of Node.js applications, along with their dependencies, into lightweight,
portable containers. This approach ensures consistent execution environments across
development, testing, and production environments, mitigating potential compatibility
issues. Leveraging Docker's containerization technology, developers can easily package
Node.js applications, manage dependencies using package.json, and define the runtime
environment using Dockerfiles. This enables streamlined development workflows,
simplified deployment processes, and improved resource utilization, making Node.js in
Docker a preferred choice for modern application development and deployment.

3. PHP

Deploying PHP applications in Docker provides developers with a robust and portable
platform for building and managing web applications. Docker allows for the
encapsulation of PHP applications and their dependencies into lightweight, self-contained
containers, ensuring consistency across different environments.

Saurabh yadav SE-IT-C 59


Steps to pull Node in Docker

Step1: Search for Node and click on node in Docker desktop.

Step 2: Copy the code.

Saurabh yadav SE-IT-C 59


Step 3: Paste in Command Prompt and run it.

Step 4: Now write docker run-it node /bin/bash and run it.

Saurabh yadav SE-IT-C 59


Step 5: Now in container click on container we made right now.

Step 6: Now click on Exec to execute code of node js.

Saurabh yadav SE-IT-C 59


Steps to pull PHP in Docker

Step 1: Search for PHP and click on PHP in Docker desktop.

Step 2: Copy the code.

Saurabh yadav SE-IT-C 59


Step 4: Paste in Command Prompt and run it.

Step 5: Write docker run php to create a container of the image pulled just now.

Saurabh yadav SE-IT-C 59


Conclusion:
In conclusion, the process of pulling an image from Docker and running it
within a container offers a seamless solution for deploying applications in
various environments. By leveraging Docker's containerization technology,
organizations can achieve consistency, portability, and scalability in their
software deployment workflows. This approach streamlines the deployment
process, allowing for efficient resource utilization and reducing potential
conflicts between dependencies. Furthermore, Docker's extensive repository of
images enables access to a wide range of pre-configured environments,
simplifying the setup and deployment of complex applications. Overall,
integrating Docker into the development and deployment pipelines empowers
teams to accelerate the delivery of software while maintaining consistency and
reliability across different environments.

Saurabh yadav SE-IT-C 59

You might also like