Git Product home page Git Product logo

gontainer's Introduction

gontainer

a lightweight containerization tool

Requirements:

  • Linux
  • A linux filesystem if you wish to containerize to a linux environment. You can get one from Alpine Linux

Usage:

How to open a shell window (Alpine linux fs)

gontainer --chrt "/home/alpine-fs" run sh 

How to open a ash window, which is like bash (Alpine linux fs)

gontainer --chrt "/home/alpine-fs" run ash 

Example on how to run python (must be installed beforehand, see Gockerfile)

gontainer --chrt "/home/alpine-fs" run python3 

VFS mount usage:

There is a file included with this repo called mnt-vfs.sh which is a script that creates a size-limited filesystem and mounts it.

Usage:

chmod +x ./mnt-vfs.sh
./mnt-vfs.sh my-fs-name 100 # Will create a 100MB vfs with the name `my-fs-name`

Creating a quota limited virtual filesystem

For this example we will create a 2GB image mounted at /mnt/my-vfs. I assume you have a alpine linux filesystem at /alpine-fs and are running everything as root.

wget http://urlTo.thefile/mnt-vfs.sh
chmod +x ./mnt-vfs.sh
./mnt-vfs.sh my-vfs 2000
cp -r /alpine-fs /mnt/my-vfs

Now you have a virtual filesystem ready with a 2GB limit! You can run gontainer on it!

gontainer --chrt /mnt/my-vfs run sh

gontainer's People

Contributors

soypat avatar nanikjava avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.