Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sqlite support #32

Open
jonocodes opened this issue Apr 24, 2024 · 6 comments
Open

sqlite support #32

jonocodes opened this issue Apr 24, 2024 · 6 comments

Comments

@jonocodes
Copy link

I'm new to cypht. It appears you can run cypht using sqlite without mysql. But I dont think this setup is supported in docker.

@wangxiaoerYah
Copy link

You can try the container image in cypht-org/cypht#975.

@jonocodes
Copy link
Author

Thanks!
Yes I tried it and after guessing the password was able to get in. By the way, how did you set up the admin account? I cant find it.
Also once logged in, I made some changes and saved them. But they did not persist when I logged out and in.

@wangxiaoerYah
Copy link

Thanks!
Yes I tried it and after guessing the password was able to get in. By the way, how did you set up the admin account? I cant find it.
Also once logged in, I made some changes and saved them. But they did not persist when I logged out and in.

The default user is set here. You can pass it via docker environment variables.

docker run -d -e CYPHT_AUTH_USERNAME=user CYPHT_AUTH_PASSWORD=1234.....

If you use sqlite it will create the directory and database here by default.

You should make it persistent.
like it.
docker run -d -v ~/cypht:/var/lib/hm3...

In general, this docker image is still being updated. After it is merged into the mainline, I will start to improve it and write documents.

@jonocodes
Copy link
Author

Thanks!
Yes I tried it and after guessing the password was able to get in. By the way, how did you set up the admin account? I cant find it.
Also once logged in, I made some changes and saved them. But they did not persist when I logged out and in.

The default user is set here. You can pass it via docker environment variables.

docker run -d -e CYPHT_AUTH_USERNAME=user CYPHT_AUTH_PASSWORD=1234.....

Ah good.

If you use sqlite it will create the directory and database here by default.

You should make it persistent. like it. docker run -d -v ~/cypht:/var/lib/hm3...

My changes are not persisting between logins. I am not restarting the service, just logging out.

In general, this docker image is still being updated. After it is merged into the mainline, I will start to improve it and write documents.

Sounds good. I look forward to the merge.

@jonocodes
Copy link
Author

Where are the credentials for my imap accounts stored? In a blob in the sqlite db?

@wangxiaoerYah
Copy link

Where are the credentials for my imap accounts stored? In a blob in the sqlite db?

By default I have set it to USER_CONFIG_TYPE=DB which will save the user settings in the database. You can also change it to file, which will store it in a file. In any case remember to persist your data directory /var/lib/hm3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants