Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] Session as DatabaseHandler Driver

(This post was last modified: 03-19-2023, 02:49 AM by superior.)


A few days ago i've started to play with DigitalOcean's App Platform to see how CodeIgniter4 runs, all seems to be working fine except for a small thing.

The issue
DigitalOcean rebuilds the application on each publication, this means they will delete everything before publishing the newly commit.
Not an issue for me but the /writable/ folder and it's contents will also be delete, this said I need a different solution for my /session/ folder.

Other folders
The cache folder is only storing information for about 5 minutes so that's not a problem.
The uploads folder is an external bucket so that folder isn't being used on my side, i'm also storing some additional information there.

CodeIgniter does offer a DatabaseHandler that will use a table named 'ci_sessions' (or a name as you desire).
This will solve the issue for me so the content will not be deleted, i'm unable to find out how this is handled.
Looked through the spark command list but under "Housekeeping" there is no session:cleanup or somehting simulair.

Q: How does CodeIgniter run a cleanup, do i need a command for this?

Messages In This Thread
[SOLVED] Session as DatabaseHandler Driver - by superior - 03-17-2023, 12:05 PM

Theme © iAndrew 2016 - Forum software by © MyBB