Rajan Silwal
  • 👋Welcome to My Personal Page
  • Project
    • 👨‍💼Daily Activities
    • ⚠️Monitoring Tools
    • ✍️Git
    • 🏎️Automation Tools
    • 💻Virtualization
    • 🖥️Immutable Infrastructure
    • 🔶Cloud (AWS)
    • ⛲Container
  • ⚠️Monitoring Tools
    • 💡Prometheus
      • How to Setup Prometheus
      • Setup Node-exporter
      • Setup Prometheus to get metrics
    • 💡Grafana
    • 💡Nagios
  • ✍️Git
    • 🐇CI/CD in Git
      • Setup Git for CICD
  • ⛲Container
    • 📍Docker
      • Docker image
      • Same Docker image in VM
  • 🚗k8s
    • Install K8S
  • 🏎️Automation Tools
    • 🖨️Ansible
      • List of my Ansible Playbook
    • Terraform
      • Setup Terraform in AWS
      • Create VPC using .tf
      • Create EC2 using .tf
      • Command Familiars in Terraform
  • 💻Virtualization
    • 🔄OpenNebula
      • Setup OpenNebula
      • Onehost Server
      • Build VM in OpenNebula
  • 🔶Cloud (AWS)
    • 🌥️EC2
    • 🌥️IAM
    • 🌥️VPC
    • 🌥️Load Balancer
    • 🌥️S3 Bucket
    • 🌥️Route 53
  • 🖥️Immutable Infrastructure
    • 1️⃣1⃣ Content
    • 2️⃣2⃣ Virt-Install
    • 3️⃣3⃣ Base Image
    • 4️⃣4⃣ Golden-Image
    • 5️⃣5⃣ After-Golden-Image
Powered by GitBook
On this page
  1. Container
  2. Docker

Same Docker image in VM

PreviousDocker imageNextInstall K8S

Last updated 2 years ago

Running same image in AWS Virtal Machine

Inorder to run the same image in VM we need to do following steps: Step 1: Create a repository in docker hub with name and push the image image to docker hub

Step 2: Once you create a repository, please login through terminal as well.

Step 3: Now, need to tag our image to our private repository: docker tag SOURCE_IMAGE[:TAG] TARGET_IMAGE[:TAG] Ex: docker tag test rajansilwal04/first_test:tagname

Step 4: Need to push our image to repository: Ex: docker push rajansilwal04/first_test:tagname

Step 6: Install Docker on Linux --> yum install docker -y

Step 7: Now, start the docker --> sudo docker start

Step 8: Since our repository is public so we can pull that image directly from internet: Ex: sudo docker run -d --rm --name test1 -p 80:80 rajansilwal04/first_test:tagname

Step 5. Create a EC2 instances ()

⛲
📍
https://app.gitbook.com/o/Sl85xsDKUHFlvowLtBga/s/9wnMXVEmEJ7k6VEhLJYN/~/changes/aNCytkzQw3O9d4ixbcKU/cloud-aws/opennebula