c = get_config() # Cấu hình xác thực PAM c.Authenticator.use_pam = True c.Authenticator.allowed_users = {'cuongpv', 'pvcuong', 'root', 'cdh'} c.Authenticator.admin_users = {'cuongpv'} c.Authenticator.allow_existing_users = True # Sử dụng PAM Authenticator c.JupyterHub.authenticator_class = 'jupyterhub.auth.PAMAuthenticator' # Tăng thời gian chờ của kernel và websocket c.MappingKernelManager.kernel_info_timeout = 300 c.MappingKernelManager.kernel_startup_timeout = 300 c.NotebookApp.websocket_ping_interval = 60 c.NotebookApp.tornado_settings = { "websocket_ping_interval": 60 } # ⚠️ QUAN TRỌNG: Thêm cấu hình proxy để fix lỗi Terminal không hoạt động c.ConfigurableHTTPProxy.command = [ 'configurable-http-proxy', '--ip', '127.0.0.1', # Nếu bạn muốn proxy lắng nghe từ ngoài thì thay bằng '0.0.0.0' '--port', '8000', '--api-ip', '127.0.0.1', '--api-port', '8001', '--error-target', 'http://127.0.0.1:8081/hub/error', '--log-level', 'info' ]