Skip to content

zacharyrs/djinn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

djinn (beta?)

An opinionated rust knockoff of genie

note: wsl2 is required!

why

i wanted to try play with rust, and dotnet is a pain on arch

usage

djinn 0.3.0
Zachary Riedlshah <[email protected]>
an opinionated rust knockoff of genie

USAGE:
    djinn [FLAGS] <SUBCOMMAND>

FLAGS:
    -v               Set verbosity
    -h, --help       Prints help information
    -V, --version    Prints version information

SUBCOMMANDS:
    init       set up a bottle
    shell      launch a shell inside bottle, sets up a bottle if necessary
    run        run a command inside bottle, sets up a bottle if necessary
    cleanup    destroy the bottle bottle

it's pretty much the same as genie but in rust

note: the subcommands infer, meaning you can just write i, s, r, and c.

requirements

like genie, djinn requires a few things...

note: the first two are likely included in your os

unlike genie, djinn doesn't need...

  • dotnet
  • hostess (not necessary in new releases of genie)

installation

  1. drop djinn into /usr/local/bin/, or /usr/bin/
  2. make sure it's owned as root, chown root:root <path to djinn>
  3. give it a setuid bit, chmod +s <path to djinn>

note: systemd environment generators

to enable wsl environment variables within the systemd environment, you may wish to add /usr/local/lib/systemd/system-environment-generators/10-djinn.sh

#!/bin/sh
if [ -e /run/djinn.env ]
then
  cat /run/djinn.env
fi

caveats

unfortunately there's still a few problems djinn can't solve...

in particular, the same bugs from genie

  • breaks /proc based tools
  • it's clunky (less than dotnet though!)

future work

though i'm sure i'll come up with something new to add, right now it's just...