GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - pogoba/hosthog: announce which resources you need on collaboratively used linux hosts

BranchesTags
Open more actions menu

Latest commit

 

History

76 Commits
76 Commits

Folders and files

NameName
Last commit message
Last commit date
src
src
 
 
.gitignore
.gitignore
 
 
Cargo.lock
Cargo.lock
 
 
Cargo.toml
Cargo.toml
 
 
DESIGN.md
DESIGN.md
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
flake.lock
flake.lock
 
 
flake.nix
flake.nix
 
 
justfile
justfile
 
 

Repository files navigation

🦔 hosthog

Announce which resources you need on collaboratively used linux hosts. Keep other processes away while you have an exclusive lock on the host.

Usage: hosthog [COMMAND]

Commands:
  status   show current claims
  claim    Claim a resource. Fails if already claimed exclusively
  release  prematurely release a claim (removes all of your hogs and exclusive claims)
  hog      Hog the entire host (others will hate you)
  post     post a message to all logged in users
  users    List all logged in users
  help     Print this message or the help of the given subcommand(s)

Options:
  -h, --help     Print help information
  -V, --version  Print version information

Example:

sudo hosthog claim --exclusive 15min some benchmarks
sudo hosthog hog

For 15 minutes other users will be locked out from ssh and tasks scheduled by systemd are paused.

Implementation status

  • claim hosthog maintains a list of claims which time out. You need an exclusive claim to hog the system.
  • hog: prevent things from happening that are not related to you
    • Clears all AuthorizedKeysFiles via bind-mounting overlay files. Locked out users receive a hosthog message when they attempt to connect via ssh.
    • Stops all systemd.timers.
  • release releases exclusive claims and reverts hog
  • users lists active users via who, and ssh sessions with netstat
  • post sends a message via wall
  • status lists claims

Installation

Optional, but recommended dependencies: at (needed to remove claims on timeout)

User-local installation via cargo: cargo install --path .

Or run it from within a nix shell: nix shell github:pogobanane/hosthog#default (timeouts won't work)

About

announce which resources you need on collaboratively used linux hosts

Resources

Readme
MIT license
Activity

Stars

5 stars

Watchers

1 watching

Forks

2 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.