R
Railway12mo ago
TheJoker

Logging user data

Hi, I'm about to put a Django project into production on Railway, at the moment in dev testing I'm logging visitors IP addresses/time stamps to a text file. Is there a proven workflow within Railway which can securely handle this sort of thing? How do I write to a file in a secure way?
4 Replies
Fragly
Fragly12mo ago
I'm pretty sure it should already be very secure, each deployment runs in an isolated environment and since you write directly to the server, the info never leaves the server Although if you mean to persist the data then you'd want to write to a volume If you need to add more security, you could encrypt it, but I'd say that's overkill, especially since you're only storing IPs
TheJoker
TheJokerOP12mo ago
Ok, i'll have look further into volumes, sorry I didn't provide project ID as this isn't a live project currently.
Fragly
Fragly12mo ago
No problem it says it closes the thread but I don't think it actually does
TheJoker
TheJokerOP12mo ago
Ah ok thanks for that. Yea pretty sure Volumes are the way to go with this. Create volume path then just use RAILWAY_VOLUME_MOUNT_PATH = /foobar/ in my Django settings and point my function that gathers the data to RAILWAY_VOLUME_MOUNT_PATH to save.
Want results from more Discord servers?
Add your server