Skip to content

Commit

Permalink
Bump 0.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
jordojordo committed May 24, 2024
1 parent fe17800 commit f01c26c
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
1 change: 1 addition & 0 deletions env.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
interface ImportMetaEnv {
readonly VITE_THOTHSCRIPT_API: string;
readonly BASE_URL: string;
readonly PROD: boolean
}

interface ImportMeta {
Expand Down
6 changes: 1 addition & 5 deletions nginx.conf.template
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,13 @@ http {
try_files $uri $uri/ /index.html;
}

# Handle WebSocket connections
location /ws/ {
proxy_pass __CLIENT_THOTHSCRIPT_API__;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_cache_bypass $http_upgrade;
access_log /var/log/nginx/websocket_access.log main;
}

error_page 500 502 503 504 /50x.html;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "thothscript",
"version": "0.1.0",
"version": "0.1.1",
"private": true,
"type": "module",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion scripts/start.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/sh

# Provide default values for CLIENT_THOTHSCRIPT_API if it's not set
: "${CLIENT_THOTHSCRIPT_API:=localhost:3000/ws}"
: "${CLIENT_THOTHSCRIPT_API:=localhost:3000}"

# Substitute environment variables in nginx.conf.template and create nginx.conf
sed "s|__CLIENT_THOTHSCRIPT_API__|http:\/\/$CLIENT_THOTHSCRIPT_API|g" /etc/nginx/nginx.conf.template > /etc/nginx/nginx.conf
Expand Down

0 comments on commit f01c26c

Please sign in to comment.