你好,

我最近更新了我的r studio到2022.07.2 Build 576,我能够成功地启动我的r工作室,但当我试图运行一个简单的hello世界,我得到连接拒绝消息,在网络选项卡中我可以看到500个错误

Nginx文件-
服务器{
监听8080 ssl;

Location / {proxy_pass http://localhost:8787;Proxy_redirect $scheme://$host:$server_port $scheme://test.com/;proxy_set_header X-英格兰vs伊朗让球RStudio-Request $scheme://$host:$server_port$request_uri;proxy_set_header X-英格兰vs伊朗让球RStudio-Root-Path /svc/rstudio/4335456$ Host:$server_port;proxy_http_version 1.1;proxy_set_header升级$http_upgradeproxy_set_header连接$connection_upgradeproxy_read_timeout 20 d;proxy_buffering; }


您的配置与文档中的配置不同英格兰vs伊朗让球RStudio工作台管理指南- 30使用代理运行。特别是proxy_redirect前两个proxy_set_header不在文档中。你有吗?地图之外的代码服务器节吗?

@rstub这是我完整的档案

pid“/ home /码头工人/ nginx / tmp / nginx.pid”;error_log“/ home /码头工人/ nginx /日志/ error.log”;事件{}HTTP {map $http_upgrade $connection_upgrade{默认升级;“关闭;} client_body_temp_path "/home/docker/nginx/tmp/client_body" 1 2;Proxy_temp_path "/home/docker/nginx/tmp/proxy" 1 2;Fastcgi_temp_path "/home/docker/nginx/tmp/fastcgi" 1 2;Scgi_temp_path /home/docker/nginx/tmp/scgi" 1 2;Uwsgi_temp_path /home/docker/nginx/tmp/uwsgi" 1 2;access_log“/ home /码头工人/ nginx /日志/ access.log”; error_log "/home/docker/nginx/log/error.log"; client_max_body_size 1024m; ssl_certificate /etc/ssl/rstudio/server.crt; ssl_certificate_key /etc/ssl/rstudio/server.key; ssl_ciphers Ett; ssl_protocols TLSv1.2; server { listen 8080 ssl; location / { proxy_pass http://localhost:8787; proxy_redirect $scheme://$host:$server_port https://test.com; proxy_set_header X-RStudio-Request $scheme://$host:$server_port$request_uri; proxy_set_header X-RStudio-Root-Path /svc/rstudio/1111; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; proxy_read_timeout 20d; proxy_buffering off; } location /nginx_status { stub_status on; access_log off; allow 127.0.0.1; #only allow requests from localhost deny all; #deny all other hosts } } }

以上几行在文档中没有类似的内容。您可以删除它们然后再试一次吗?

@rstub
删除以上线条后,我得到这个
在header中,这个url正在形成

我还补充了$ Host:$server_port;

地点:

https://https: / auth-sign-in吗?appUri = % 2 f

该内容被阻止。请与网站所有者联系以解决此问题。

@rstub你能帮帮忙吗

目前我不知道这个重复的“https”在位置可能来自哪里。你能提供一个可复制的例子,例如使用Docker文件吗?

@rstub

我用的是rstudio版英格兰vs伊朗让球本1.2.1335下面是nginx.conf

Location / {proxy_pass http://localhost:8787;Proxy_redirect http://localhost:8787/ $scheme://$http_host;proxy_http_version 1.1;proxy_set_header升级$http_upgradeproxy_set_header连接$connection_upgradeproxy_read_timeout 20 d;proxy_buffering;}

上面的版本在这个conf下运行得很顺利,
但是现在当我们升级到r studio版本时2022.07.2 + 576它开始产生问题

https://localhost:8787/auth-sign-in?appUri=%2F

带状态码302

https://localhost:8787/auth-sign-in?appUri=%2F(“frame-src”)。
Pfa截图

我试图使用遵循我们文档的最小nginx配置来重现该问题:

$ cat docker-compose。- PASSWORD=rst英格兰vs伊朗让球udio12 proxy: image: nginx volumes: - ./nginx.conf:/etc/nginx/nginx.conf: - "80:80" $ cat nginx.conf events {} http {map $http_upgrade $connection_upgrade{默认升级;“关闭;}服务器{监听80;Location / {proxy_pass http://r英格兰vs伊朗让球studio:8787;proxy_http_version 1.1;proxy_set_header升级$http_upgradeproxy_set_header连接$connection_upgrade$ Host:$server_port;proxy_read_timeout 20 d; } } } $ docker-compose -d

到目前为止,一切正常。您是否可以使用此配置并更改它,以便再现您的问题?

为什么要用rstudio:878英格兰vs伊朗让球7,不应该是proxy_pass吗http://localhost:8787

docker-compose代理服务器运行在与RStudio服务器不同的“节点”上。英格兰vs伊朗让球前者叫做代理后者叫做英格兰vs伊朗让球

此主题在最后一次回复后21天自动关闭。不再允许新的回复。

如果你有一个与它或其中一个回复相关的问题,开始一个新的主题,并引用一个链接。