feat: Implement server CLI interface (bssh-server binary) (#131) #150
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR implements the
bssh-serverbinary with a comprehensive CLI interface for starting and managing the SSH server, resolving issue #131.Implementation Details
Commands Implemented
Global CLI Arguments
-c, --config- Configuration file path-b, --bind-address- Bind address override-p, --port- Port override-k, --host-key- Host key file(s) override-v, --verbose- Verbosity level (repeatable: -v, -vv, -vvv)-D, --foreground- Run in foreground--pid-file- PID file pathFeatures
✓ Configuration loading from YAML files with CLI overrides
✓ Signal handling for graceful shutdown (SIGTERM, SIGINT)
✓ Password hashing with bcrypt (cost factor 12)
✓ SSH host key generation (Ed25519 recommended, RSA supported)
✓ Configuration validation and checking
✓ Proper error handling and exit codes
✓ Integration with existing ServerFileConfig from #130
Technical Changes
src/bin/bssh_server.rswith full CLI implementationCargo.tomlto add binary target and dependencies:bssh-server.yamlto.gitignoreTesting
-D warningsUsage Examples
Related Issues
Checklist