New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Request - Allow change of default host #94
Comments
This is a great idea! You can expect this feature in the next commit. |
I just pushed a commit that adds this feature. To enable it you just need to add "--default_host='yourhostname'" to the 'command' in your server.conf:
That will make the prompt look like so:
If you want to disable the default host altogether just set default_host equal to an empty string like so:
Give it a try and let me know how it goes. Thanks! |
That seems to work great. I set it to not have a default host and it omitted it as expected and also errored indicating it needed a valid one which was also what I wanted. Thanks! |
Great! I'm going to close out this issue then. Please open more tickets for more features like this! I love the easy ones :) |
utils.py: Added drop_privileges() so we can run as a user/group other than root. gateone.py: Gate One now supports --uid and --gid to enable dropping of privileges. These two options can take a string or an integer (e.g. 'gateone' or '1005' will work). This means that if you run Gate One as root it will open the listening port (e.g. 443) and then drop to the given user/group. It automatically tries to fix the permissions of writable directories (user_dir, session_dir, logs, etc) and does its best to figure out what supplemental group owns /dev/pts so it can be added to the executing supplemental groups. gateone.py: Many directories that were previously created with chmod 0700 are now being created using 0770 (in case someone wants to manage access based on the owning group). gateone.py: Added two new plugin hooks that allow arbitrary code to be placed in the header and body of index.html. This is primarily to make it easier for plugins to include 3rd party JavaScript libraries but it should also be an all-around useful feature. ssh_connect.py: Added the ability to specify a default_host for all connections. This will allow you to have something other than [localhost] in the SSH connection prompt. Also, if you pass this option an empty string (--default_host="") it will force the user to enter a valid hostname (i.e. no default). This should take care of the following feature request: liftoff#94
When authenticated the default host of the session is localhost. Can we get an option to customize it to point somewhere else or even to leave it blank? If it is blank it would require it to be populated by simply looping back to the prompt when it is empty.
The text was updated successfully, but these errors were encountered: