File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2323$ id = uniqid ();
2424file_put_contents ("/tmp/ $ id.json " , json_encode ($ _GET ));
2525
26- header ("Location: http ://shell.opencloudshell.com:7681 /?arg= $ id " );
26+ header ("Location: https ://shell.opencloudshell.com/?arg= $ id " );
Original file line number Diff line number Diff line change 165165 const { useMemo, useState } = React ;
166166
167167 function App ( ) {
168- const [ endpoint , setEndpoint ] = useState ( "http ://shell.opencloudshell.com/connect.php" ) ;
168+ const [ endpoint , setEndpoint ] = useState ( "https ://shell.opencloudshell.com/connect.php" ) ;
169169 const [ port , setPort ] = useState ( "" ) ;
170170 const [ destination , setDestination ] = useState ( "" ) ;
171171 const [ password , setPassword ] = useState ( "" ) ;
Original file line number Diff line number Diff line change 1+ map "$uri$arg_arg" $index_no_arg {
2+ "/" 1;
3+ default 0;
4+ }
5+
6+ server {
7+ listen 80 default_server;
8+ listen [::]:80 default_server;
9+ listen 443 ssl default_server;
10+ listen [::]:443 ssl default_server;
11+ ssl_certificate /etc/letsencrypt/live/shell.opencloudshell.com/fullchain.pem;
12+ ssl_certificate_key /etc/letsencrypt/live/shell.opencloudshell.com/privkey.pem;
13+ include /etc/letsencrypt/options-ssl -nginx.conf;
14+ ssl_dhparam /etc/letsencrypt/ssl -dhparams.pem;
15+
16+ root /root /OpenCloudShell;
17+
18+ index index .html index .htm index .nginx-debian.html;
19+
20+ server_name _;
21+
22+ location ~ \.php$ {
23+ include snippets/fastcgi-php.conf;
24+ fastcgi_pass unix:/var/run/php/php8.4-fpm.sock;
25+ }
26+
27+ location ~ ^/__serve_static( .*) $ {
28+ internal ;
29+ rewrite ^/__serve_static( .*) $ $1 break ;
30+ try_files $uri $uri / =404 ;
31+ }
32+
33+ location / {
34+ if ( $index_no_arg ) {
35+ rewrite ^ /__serve_static$uri last;
36+ }
37+ proxy_http_version 1.1;
38+ proxy_set_header Host $host ;
39+ proxy_set_header X-Forwarded-Proto $scheme ;
40+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
41+ proxy_set_header Upgrade $http_upgrade ;
42+ proxy_set_header Connection "upgrade" ;
43+ proxy_pass http ://127.0.0.1:7681 ;
44+ }
45+ }
Original file line number Diff line number Diff line change @@ -3,7 +3,13 @@ apt install -y nginx php php-fpm certbot python3-certbot-nginx
33systemctl stop apache2
44systemctl disable apache2
55
6+ nginx -t
7+ systemctl restart nginx
8+
69git clone https://github.com/GitHub30/OpenCloudShell
710vi /etc/nginx/sites-available/default
811vi /etc/default/ttyd
912systemctl restart ttyd
13+
14+ certbot --nginx -d opencloudshell.com -d www.opencloudshell.com
15+ certbot --nginx -d shell.opencloudshell.com
You can’t perform that action at this time.
0 commit comments