Files
lxs/README.md
T
hykocx fc50a71763 feat(tools): add root-password and update-server tools
- add `tools/root-password.sh` to change root password interactively or generate a random one
- add `tools/update-server.sh` to run apt update/upgrade/autoremove/autoclean
- register both tools in `lxs.sh` dispatcher and `tools/index.sh` interactive menu
- document new tools in README.md
2026-05-12 21:39:38 -04:00

95 lines
3.8 KiB
Markdown

# LXS
Linux multi-tool — a Bash menu and CLI for installing common server apps and running system tools on Debian/Ubuntu.
## Quick install
```bash
curl -fsSL https://git.hyko.cx/hykocx/lxs/raw/branch/main/lxs.sh | sudo bash -s -- setup
```
This downloads the repo tarball, installs every file to `/usr/local/share/lxs/`, and creates the symlink `/usr/local/bin/lxs`. After install, sub-scripts run from disk — no network calls per command.
> Avoid `sudo bash <(curl …)` — process substitution opens `/dev/fd/63` in your shell, which the root `bash` spawned by `sudo` cannot read (`bash: /dev/fd/63: No such file or directory`). Pipe through `sudo bash -s --` instead.
Or run once without installing (no `sudo` needed for the entrypoint — sub-scripts auto-elevate when they need root):
```bash
curl -fsSL https://git.hyko.cx/hykocx/lxs/raw/branch/main/lxs.sh | bash
```
When a new version is published in this repo, the interactive menu shows a *"Nouvelle version disponible"* banner; run `lxs update` to pull all updated files.
## Usage
```bash
lxs # Interactive menu (checks for updates, cached 24h)
lxs setup # First-time install of all files to /usr/local/share/lxs
lxs update # Update all installed files to latest
lxs install <app> # Install an application
lxs tool <name> [args] # Run a system tool
lxs info # Show system info
lxs version # Show version
lxs help # Show help
```
### Applications
| Command | Description |
|---|---|
| `lxs install coolify` | Self-hosted PaaS |
| `lxs install pterodactyl` | Game server management panel |
| `lxs install uptime-kuma` | Monitoring tool |
| `lxs install cloudpanel` | Web hosting control panel |
| `lxs install proxmox` | Proxmox VE management tools |
### Tools
| Command | Description |
|---|---|
| `lxs tool system` | System monitoring and diagnostics |
| `lxs tool benchmark` | Server benchmark (CPU / RAM / disk / network) |
| `lxs tool harden` | Baseline hardening: UFW + fail2ban + SSH key-only + unattended-upgrades |
| `lxs tool root-password` | Change the root password (interactive or generated) |
| `lxs tool update` | Update the server (apt update + upgrade + autoremove + autoclean) |
## Project structure
```
lxs/
├── lxs.sh # Main entrypoint (menu + CLI dispatcher)
├── VERSION # Single source of truth for the version (bump on every release)
├── lib/
│ └── common.sh # Shared helpers (colors, loggers, spinner)
├── apps/ # Application installers
│ ├── index.sh # Interactive menu listing the apps below
│ ├── coolify.sh
│ ├── pterodactyl.sh
│ ├── uptime-kuma.sh
│ ├── cloudpanel.sh
│ └── proxmox.sh
└── tools/ # System tools
├── index.sh # Interactive menu listing the tools below
├── system-infos.sh
├── server-benchmark.sh
├── harden.sh
├── root-password.sh
└── update-server.sh
```
After `lxs setup`, the full tree lives in `/usr/local/share/lxs/` and sub-scripts execute from disk. If `lxs.sh` is run without being installed (the one-liner mode), it falls back to downloading sub-scripts on demand.
### Releasing a new version
Bump only the [VERSION](VERSION) file — `lxs.sh` reads it at startup. Installed clients also fetch this file (cached 24 h in `~/.cache/lxs/`) to detect updates. In one-shot mode (`curl … | bash`) the file isn't on disk next to the script, so `lxs version` reports `dev`.
## Requirements
- Debian or Ubuntu (other distros may work but are not tested)
- `curl`
- Some sub-scripts require root; they will auto-elevate via `sudo` when run.
## License
MIT