hywax / lxc-idmapper

LXC unprivileged mapper

Home Page:https://hywax.space/projects/lxc-id-mapper

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LXC ID Mapper

npm version License

LXC ID Mapper is a library designed to map container GIDs to host UIDs for LXC containers. This library provides a simple and efficient way to manage user and group IDs in a containerized environment, ensuring that the correct permissions are applied and that the security of the host system is maintained.

Table of Contents

πŸ§ͺ Usage

Playground

Try the library online using the provided playground - visit playground.

Basic

import { mapper } from 'lxc-id-mapper'

const result = mapper([
  { containerId: 1000, hostId: 1005 }
])

console.log(result.idMap) // Outputs the mapped IDs

πŸš€ Installation

# Using pnpm
pnpm add lxc-idmapper -D

# Using yarn
yarn add lxc-idmapper -D

# Using npm
npm install lxc-idmapper -D

πŸ† Credits

A huge thank you to everyone who is helping to improve Mafl. Thanks to you, the project can evolve!

Contributors

To become a contributor, please follow our contributing guide.

Contributors

πŸ“„ License

This template was created under the MIT License.

About

LXC unprivileged mapper

https://hywax.space/projects/lxc-id-mapper

License:MIT License


Languages

Language:TypeScript 74.3%Language:JavaScript 11.0%Language:HTML 10.9%Language:Shell 3.7%