Skip to content

prasad0679/containers-from-scratch

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Container from Scratch

NOTE: you'll need linux to run this, doesnt work on macOS/Windows

Simple Run

go run main.go run_one echo "hello from container"
go run main.go run_one /bin/bash

Simple Container

Download Ubuntu Base from http://cdimage.ubuntu.com/ubuntu-base/releases/20.04/release/

tar -xvf ubuntu-base-20.04.1-base-amd64.tar.gz -C rootfs

Modify steps/two.go

	must(syscall.Chroot("/home/satyajit/temp/container-from-scratch/rootfs"))
sudo go run main.go run_two /bin/bash

or

go build
sudo ./container-from-scratch run_two /bin/bash

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%