Skip to content

Commit

Permalink
Increase number of file descriptors available to the playground
Browse files Browse the repository at this point in the history
With the WebSocket functionality, we now have a number of latent
connections hanging out.
  • Loading branch information
shepmaster committed Jun 23, 2023
1 parent 3a5aecc commit 80c7fcc
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions ansible/playbooks/playground.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
- "{{ vars_playground_domain }}"

- role: nginx
worker_connections: "{{ vars_playground_number_connections }}"
proxied:
- domain: "{{ vars_playground_domain }}"
to: "http://127.0.0.1:{{ vars_playground_env_ui_port }}"
Expand Down
4 changes: 4 additions & 0 deletions ansible/roles/playground/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,7 @@ vars_playground_env_cors_enabled: 1
vars_playground_env_ui_address: 127.0.0.1
vars_playground_env_ui_port: 8080
vars_playground_env_ui_root_path: "{{ vars_playground_artifacts_path }}/build"

# The playground peaks at a bit less than 2000 open file descriptors
# over a normal week, so give ourselves a little bit of a buffer.
vars_playground_number_connections: 2560
2 changes: 2 additions & 0 deletions ansible/roles/playground/templates/playground.service
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,7 @@ WorkingDirectory={{ vars_playground_artifacts_path }}

ExecStart={{ vars_playground_executable_path }}

LimitNOFILE={{ vars_playground_number_connections }}

[Install]
WantedBy=multi-user.target

0 comments on commit 80c7fcc

Please sign in to comment.