-
Notifications
You must be signed in to change notification settings - Fork 292
Merge SSH auto-mode feature to next #6597
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
Conversation
Add new host object fields: - ssh_auto_mode Add new host/pool API to enable to set auto mode - set_ssh_auto_mode Signed-off-by: Lunfan Zhang <[email protected]>
Implemented XAPI APIs for SSH auto mode configuration: - `host.set_ssh_auto_mode`: Configures SSH auto mode for a specific host. - `pool.set_ssh_auto_mode`: Configures SSH auto mode for all hosts in the pool. Additionally: - `host.enable_ssh` now automatically sets SSH auto mode to `false`. Signed-off-by: Lunfan Zhang <[email protected]>
Updated `records.ml` file to support `host-param-set/get/list` and `pool-param-set/get/list` for ssh-auto-mode. Signed-off-by: Lunfan Zhang <[email protected]>
This PR introduces support for Dom0 SSH control, providing the capability to configure the auto mode for a specific host or all hosts in the pool. New Host Object Fields and Host/Pool API: - `ssh_auto_mode`: Indicates whether SSH auto mode is enabled. configure to true means startup SSH when the XAPI service is down; stop SSH when the XAPI service is up. configure to false means SSH service status is independent and not effected by the XAPI service status. - `set_ssh_auto_mode`: Allows setting auto mode for specific host or all hosts in the pool. (Note: Default value for XS8/XS9, pool join/eject operations, and XAPI startup scenarios will be addressed in the next PR, this PR only include the change of data_mode/API/cli )
- For XS8, a configuration file (/etc/xapi.conf.d/ssh-auto-mode.conf) will be loaded, and auto_mode will be set to false. - For XS9, no configuration file exists, so the default value will be set to true. Signed-off-by: Lunfan Zhang[Lunfan.Zhang] <[email protected]>
- Copy auto mode setting from pool coordinator in pool join - Restore auto mode setting to default when pool eject Signed-off-by: Lunfan Zhang[Lunfan.Zhang] <[email protected]>
…lt Values (#6484) This PR aim to add following change for auto-mode: Copy the auto-mode setting from the pool coordinator during a pool join. and restore the auto-mode setting to default value when a pool eject occurs. - In XS8, the auto-mode is set to false by loading the config file `/etc/xapi.conf.d/ssh-auto-mode.conf`. - In XS9, default value is set to true.
Merge master to feature branch
- Move `set_ssh_expiry` outside of the `schedule_disable_ssh_job` to avoid restart XAPI reset host.ssh_expiry - Ensure the SSH service is enabled during auto-mode Signed-off-by: Lunfan Zhang[Lunfan.Zhang] <[email protected]>
- Move the `set_ssh_expiry` outside of the `schedule_disable_ssh_job` to avoid restart XAPI reset host.ssh_expiry - Ensure the SSH service is always enabled during auto-mode
…exceeds the timeout duration Signed-off-by: Lunfan Zhang[Lunfan.Zhang] <[email protected]>
…exceeds the timeout duration (#6574) When XAPI fails for an extended period that exceeds the timeout duration, it loses the original auto-mode setting that was configured before the timeout. After XAPI restarts, the auto-mode should be reset to true for security purposes.
For the following scenarios, console timeout may not reflect the real status of the database: - XenServer upgrade to a new version - User accidentally deletes the configuration file Add checks to ensure database and real status are matched. Signed-off-by: Lunfan Zhang[Lunfan.Zhang] <[email protected]>
|
There are 2 conflicts. Should we resolve them? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please resolve the conflicts first.
|
Close this PR as schema hash is conflicted |
|
The design docs need to be included before merging the feature to master as well:
|
|
Design docs added at: #6608 |
No description provided.