You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when im trying to paste anything in i get an infinite loading screen, i cant see anything abnormal in the logs, but i got this error in the webconsole right after pasting:
Uncaught (in promise) SyntaxError: Unexpected token < in JSON at position 0
Encountered with opera gx and edge.
Im hosting paaster within docker from a raspberry pi, here is my docker-compose:
version: '3'
services:
starlette:
container_name: paaster_backend
image: wardpearce/paaster-backend
restart: unless-stopped
ports:
- "8888:80"
environment:
MONGO_IP: "paaster_mongodb"
MONGO_PORT: 27017
MONGO_DB: "paaster"
# Nano ID length https://zelark.github.io/nano-id-cc/
NANO_ID_LEN: 21
# Chunk size when sending a encrypted paste back to the client.
READ_CHUNK: 1024
# This is the max paste size of the encrypted data.
MAX_PASTE_SIZE_MB: 3
REDIS_HOST: "paaster_redis"
REDIS_PORT: 6379
# Proxied Frontend URL.
FRONTEND_PROXIED: "http://localhost:8889"
volumes:
# If you change 'SAVE_PATH' this needs to be changed,
# changing 'SAVE_PATH' is not recommended.
- appdata:/app/pastes
depends_on:
- mongodb
networks:
- backend
Hey, this is most likely a CORs issue. both VITE_BACKEND & FRONTEND_PROXIED need to be the exposed address / domain of your hosted instance of paaster (domain assuming you have reversed proxied them).
For paaster.io for example, VITE_BACKEND: "https://api.paaster.io" & FRONTEND_PROXIED: "https://paaster.io"
Uncaught (in promise) SyntaxError: Unexpected token < in JSON at position 0 this error is due to the web client not actually receiving JSON, whats mostly likely because the VITE_BACKEND isn't pointing at the right location.
when im trying to paste anything in i get an infinite loading screen, i cant see anything abnormal in the logs, but i got this error in the webconsole right after pasting:
Uncaught (in promise) SyntaxError: Unexpected token < in JSON at position 0
Encountered with opera gx and edge.
Im hosting paaster within docker from a raspberry pi, here is my docker-compose:
version: '3'
services:
starlette:
container_name: paaster_backend
image: wardpearce/paaster-backend
restart: unless-stopped
ports:
- "8888:80"
environment:
MONGO_IP: "paaster_mongodb"
MONGO_PORT: 27017
MONGO_DB: "paaster"
# Nano ID length https://zelark.github.io/nano-id-cc/
NANO_ID_LEN: 21
# Chunk size when sending a encrypted paste back to the client.
READ_CHUNK: 1024
# This is the max paste size of the encrypted data.
MAX_PASTE_SIZE_MB: 3
REDIS_HOST: "paaster_redis"
REDIS_PORT: 6379
# Proxied Frontend URL.
FRONTEND_PROXIED: "http://localhost:8889"
volumes:
# If you change 'SAVE_PATH' this needs to be changed,
# changing 'SAVE_PATH' is not recommended.
- appdata:/app/pastes
depends_on:
- mongodb
networks:
- backend
vite:
container_name: paaster_frontend
image: wardpearce/paaster-frontend
environment:
VITE_BACKEND: "http://localhost:8888"
VITE_NAME: "paaster"
restart: unless-stopped
ports:
- "8889:80"
redis:
container_name: paaster_redis
image: redis
volumes:
- redis:/data
networks:
- backend
mongodb:
image: mongo:4.4.14
container_name: paaster_mongodb
restart: unless-stopped
environment:
MONGODB_DATA_DIR: /data/db
MONDODB_LOG_DIR: /dev/null
volumes:
- mongodbdata:/data/db
networks:
- backend
networks:
backend:
driver: bridge
volumes:
redis:
driver: local
mongodbdata:
driver: local
appdata:
driver: local
The text was updated successfully, but these errors were encountered: