Closed acseven closed 1 month ago
i have to update the docs, it is not clear enough, and there's a typo.
sqlite db is in database_schema folder, so /prisma/sqlite/db.sqlite, try to mount it that way
- /docker/tools-prod-snapp-url-short/v/db/db.sqlite:/app/prisma/sqlite/db.sqlite
edit: sorry my mistake, i closed the issue clicking on the wrong button. let me know if it is ok now :)
Hi, thanks for the reply. That did solve the db.sqlite
issue which now has content.
However, I'm still unable to login with the ADMIN_USERNAME
and ADMIN_PASSWORD
environment credentials, or with admin
/password
if those are unset. The browser console reads the following errors (I've tried both using direct IP access and a local UPN via Nginx):
Container logs don't point to anything abnormal:
Prisma schema loaded from prisma/sqlite/schema.prisma
✔ Generated Prisma Client (v5.18.0) to ./node_modules/@prisma/client in 310ms
Start by importing your Prisma Client (See: http://pris.ly/d/importing-client)
Tip: Curious about the SQL queries Prisma ORM generates? Optimize helps you enhance your visibility: https://pris.ly/tip-2-optimize
npm notice
npm notice New minor version of npm available! 10.8.2 -> 10.9.0
npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.9.0
npm notice To update run: npm install -g npm@10.9.0
npm notice
Prisma schema loaded from prisma/sqlite/schema.prisma
Datasource "db": SQLite database "db.sqlite" at "file:./db.sqlite"
1 migration found in prisma/migrations
Applying migration `20240808202925_init`
The following migration(s) have been applied:
migrations/
└─ 20240808202925_init/
└─ migration.sql
All migrations have been successfully applied.
-------------------------------------------
Welcome to Snapp!
-------------------------------------------
Thank you for choosing this app.
Have a great day and enjoy your
experience with us!
-------------------------------------------
Listening on 0.0.0.0:3000
VirusTotal API Key: configuration added to the database.
SMPT Setup: configuration added to the database.
What could be wrong?
Edit: that's a minor typo in the last log line "SMPT" instead of "SMTP", right?
you should use the same ORIGIN as ENV, the console log of your screen seems to redirect to http://snapp.-----.local, while your docker compsoe is https://url.
if using it on http:// remember env NODE_ENV to development try to match those two :)
edit: thanks for the typo i'll add that to the next release :)
Thank you, that was it. I was [stupidly] expecting to be able to have an external URL set for the actual shortened URLs while only having local access to the dashboard. My apologies!
Thank you for this tool, it's looking great! If I may add some suggestions for future additions:
Actually you can, i never thought of it cause i prefer send my password through https, but if you mean to access it through VPN or in secure way, well it must match origin: .local
the get call for taking the url and redirecting (the frontend final use) can happen via https:// anyway, it doesn't use auth or stuff like that
i'm not sure about security thou.
OAUTH i think would require a privacy policy and can't be compliant with gdpr as cookieless authentication, i preferred keeping it simple.
On prevent admin deleting, well have to be honest happened to me too and i thought i fix'd it. i'll look into thaat
On prevent admin deleting, well have to be honest happened to me too and i thought i fix'd it. i'll look into thaat
Thanks, so you understand the nuisance 😅
Actually you can, i never thought of it cause i prefer send my password through https, but if you mean to access it through VPN or in secure way, well it must match origin: .local
the get call for taking the url and redirecting (the frontend final use) can happen via https:// anyway, it doesn't use auth or stuff like that
I'm not sure I understood, but having unencrypted local access isn't a big deal in my case, but I do want the generated URLs to be available on the internet! Meaning having the ui on snapp.mylan.local
and urls accessible on *.urls.mydomain.com
, hence preventing public access to the UI.
so it should work as long as ORIGIN is the domain of the endpoint you want to login at :)
Hi,
I'm trying to try out snapp but I'm having issues with logging in, and it seems that the database isn't getting populated with data, I can't seem to find what I'm doing wrong here.
Here's what I have in the composer file (Portainer):
I've created an empty
db.sqlite
file on the volume location.The logs state:
While trying to login the console reads:
Failed to load resource: the server responded with a status of 403 (Forbidden)
What could be wrong here?