mirror of https://github.com/jumpserver/jumpserver
Merge pull request #9812 from jumpserver/pr@dev@perf_rd_license
perf: 优化 RD License 配置pull/9824/head
commit
410668c209
|
@ -7,7 +7,7 @@
|
|||
HOST_ID: 00000000-0000-0000-0000-000000000000
|
||||
CORE_HOST: https://demo.jumpserver.org
|
||||
BOOTSTRAP_TOKEN: PleaseChangeMe
|
||||
RDS_Licensing: true
|
||||
RDS_Licensing: false
|
||||
RDS_LicenseServer: 127.0.0.1
|
||||
RDS_LicensingMode: 4
|
||||
RDS_fSingleSessionPerUser: 1
|
||||
|
@ -16,13 +16,6 @@
|
|||
TinkerInstaller: Tinker_Installer.exe
|
||||
|
||||
tasks:
|
||||
- name: Install RDS-Licensing (RDS)
|
||||
ansible.windows.win_feature:
|
||||
name: RDS-Licensing
|
||||
state: present
|
||||
include_management_tools: yes
|
||||
when: RDS_Licensing
|
||||
|
||||
- name: Install RDS-RD-Server (RDS)
|
||||
ansible.windows.win_feature:
|
||||
name: RDS-RD-Server
|
||||
|
@ -78,11 +71,23 @@
|
|||
state: present
|
||||
register: win_install_python
|
||||
|
||||
- name: Check pip command exists
|
||||
ansible.windows.win_powershell:
|
||||
script: |
|
||||
if (Get-Command -Name 'pip' -ErrorAction SilentlyContinue) {
|
||||
$Ansible.Changed = $false
|
||||
}
|
||||
else {
|
||||
$Ansible.Changed = $true
|
||||
}
|
||||
register: check_pip_command
|
||||
ignore_errors: yes
|
||||
|
||||
- name: Reboot if installing requires it
|
||||
ansible.windows.win_reboot:
|
||||
post_reboot_delay: 10
|
||||
test_command: whoami
|
||||
when: rds_install.reboot_required or win_install_python.reboot_required
|
||||
when: check_pip_command.changed or rds_install.reboot_required or win_install_python.reboot_required
|
||||
|
||||
- name: Set RDS LicenseServer (regedit)
|
||||
ansible.windows.win_regedit:
|
||||
|
@ -90,6 +95,7 @@
|
|||
name: LicenseServers
|
||||
data: "{{ RDS_LicenseServer }}"
|
||||
type: string
|
||||
when: RDS_Licensing
|
||||
|
||||
- name: Set RDS LicensingMode (regedit)
|
||||
ansible.windows.win_regedit:
|
||||
|
@ -97,6 +103,7 @@
|
|||
name: LicensingMode
|
||||
data: "{{ RDS_LicensingMode }}"
|
||||
type: dword
|
||||
when: RDS_Licensing
|
||||
|
||||
- name: Set RDS fSingleSessionPerUser (regedit)
|
||||
ansible.windows.win_regedit:
|
||||
|
@ -104,6 +111,7 @@
|
|||
name: fSingleSessionPerUser
|
||||
data: "{{ RDS_fSingleSessionPerUser }}"
|
||||
type: dword
|
||||
when: RDS_Licensing
|
||||
|
||||
- name: Set RDS MaxDisconnectionTime (regedit)
|
||||
ansible.windows.win_regedit:
|
||||
|
@ -207,4 +215,3 @@
|
|||
- name: Sync all remote applets
|
||||
ansible.windows.win_shell:
|
||||
"tinkerd install all"
|
||||
|
||||
|
|
Loading…
Reference in New Issue