Skip to content
Snippets Groups Projects
Commit a68943d1 authored by Stephane Armanet's avatar Stephane Armanet
Browse files

add session limit per NX node

parent 4f5c9fb8
No related branches found
No related tags found
No related merge requests found
Pipeline #184780 passed
......@@ -14,3 +14,4 @@ node_exporter_textfile_dir: /var/lib/node_exporter/
nomachine_node_extra_pkg:
- tcpdump
- filezilla
nomachine_node_max_sessions: 8
......@@ -20,6 +20,15 @@
mode: 0644
notify: restart_nx
- name: setup nx node server.cfg
template:
src: nx_server.cfg.j2
dest: /usr/NX/etc/server.cfg
owner: nx
group: nx
mode: 0644
notify: restart_nx
- name: setup nx desktop
template:
src: start-desktop
......
# {{ ansible_managed }}
ConfigFileVersion 4.0
SessionLogLevel 6
SystemLogFile /var/log/nxserver.log
ConnectionsLimit 30
ConnectionsUserLimit 2
VirtualDesktopsLimit 30
VirtualDesktopsUserLimit 2
EnablePersistentSession all
EnableClipboard both
EnableUserDB 0
EnablePasswordDB 0
ConnectPolicy autocreate=1,autoconnect=1,automigrate=1,desktop=0,dialog=1
StartHTTPDaemon Automatic
StartNXDaemon Automatic
ClientConnectionMethods NX,SSH,HTTP
SSHAuthorizedKeys authorized_keys2
VirtualDesktopSharing 1
VirtualDesktopMode 2
VirtualDesktopAuthorization 1
PhysicalDesktopSharing 0
UserScriptBeforeSessionStart "/usr/local/bin/before_session"
UserScriptAfterSessionClose "/usr/local/bin/after_session"
UserScriptBeforeSessionReconnect "/usr/local/bin/before_session"
AvailableSessionTypes unix-remote,unix-console,unix-default,unix-application,physical-desktop,shadow,unix-xsession-default,unix-gnome,unix-xdm,vnc,windows
RunNodeMode 1
EnableFirewallConfiguration 1
EnableScreenLock 0
# {{ ansible_managed }}
ConfigFileVersion 4.0
SessionLogLevel 6
EnablePasswordDB 0
ClientConnectionMethods NX,SSH
SSHAuthorizedKeys authorized_keys
ConnectionsLimit {{ nomachine_node_max_sessions }}
VirtualDesktopsLimit {{ nomachine_node_max_sessions }}
AvailableSessionTypes unix-remote,unix-console,unix-default,unix-application,physical-desktop,shadow,unix-xsession-default,unix-gnome,unix-xdm,windows
WebReferrer ""
WebRedirect ""
Section "Server"
Name "Connection to localhost"
Host 127.0.0.1
Protocol NX
Port 4000
Authentication password
EndSection
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment