self-host-csmm-support
textPage 68 of 373
50 messages on this page
Sunday, April 23, 2023
User 0f10b2
both?
User bddf69
Are you using the latest (and/or the same) version for both the containers?
User 0f10b2
Still not working, and logs last with:
csmm-migrations_1 | No migrations were executed, database schema was already up to date.User 0f10b2
Nice! Thank you!
User bddf69
Are you using the docker-compose? There's a container specifically for that: https://github.com/CatalysmsServerManager/7-days-to-die-server-manager/blob/master/docker-compose.yml#L33
Start that one with
docker-compose start csmm-migrations and it should run the migrations for you. You can use docker-compose logs csmm-migrations to check if there were any errorsUser 0f10b2
I did know how to do it with npm but now I’m with docker, I got no idea. 😢
User bddf69
You need to run database migrations
Friday, April 21, 2023
User bddf69
Any errors when you try and delete or edit a variable
Could also be useful to look at the network tab of your browser dev tools too, if you know how to ^^
User 0f10b2
It was working until I update to last version. I installed through docker. I’ll check logs when I will be home. Is there something particular I gotta check?
Thursday, April 20, 2023
User bddf69
Since you are self hosting there could be a lot of stuff wrong. Did you try debugging? Check csmm logs, check browser error logs
User 0f10b2
Hello, i got something weird in experiments: I cannot delete neither edit variables. Something I missed?
Wednesday, April 19, 2023
User bddf69
Nice one! Glad you got it going :D
Tuesday, April 18, 2023
User 7043bc
Hey, me again.
I'm sorry I've been such a pain the last few days.
I just wanted to thank you again for the quick and competent help. Honestly. Thank you so much. I could never have done this without your help.
I'm sorry I've been such a pain the last few days.
I just wanted to thank you again for the quick and competent help. Honestly. Thank you so much. I could never have done this without your help.
turning the command off was a very good hint.
That and a little google was needed and it works <:peepoBigSmile:914044529978507345>
That and a little google was needed and it works <:peepoBigSmile:914044529978507345>

its_working.png
PNG • 19.4 KB
User bddf69
You can't have Caddy running in docker AND the systemd service running. Delete/disable the systemd service
About your caddy config: this is Docker networking again so use the DNS names of containers you want to route to instead of localhost
Monday, April 17, 2023
User 7043bc
rottenredemption.duckdns.org {
reverse_proxy localhost:1337
}
reverse_proxy localhost:1337
}
Error: sending configuration to instance: performing request: Post "http://localhost:2019/load": dial tcp [::1]:2019: connect: connection refused
Doesn't seem to be that simple, or I did something wrong again.
By the way, what else I noticed:
● caddy.service - Caddy
Loaded: loaded (/lib/system/system/caddy.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mon 2023-04-17 20:26:42 UTC; 1h 0min ago
Docs: https://caddyserver.com/docs/
Main PID: 958870 (code=exited, status=1/FAILURE)
Status: "loading new config: http app module: start: listening on :80: listen tcp :80: bind: address already in use"
CPU: 40ms
Loaded: loaded (/lib/system/system/caddy.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mon 2023-04-17 20:26:42 UTC; 1h 0min ago
Docs: https://caddyserver.com/docs/
Main PID: 958870 (code=exited, status=1/FAILURE)
Status: "loading new config: http app module: start: listening on :80: listen tcp :80: bind: address already in use"
CPU: 40ms
Could this be the reason why caddy is having problems?
I will have a look at it in the days. If I can do it alone, rather unlikely.
Nevertheless, I thank you very much for all the help.
Really. Thanks a lot
Really. Thanks a lot
User bddf69
About Caddy, I don't really know what's going wrong, it's hard to pinpoint.
Currently, you're using the command method of Caddy to create the reverse proxy, that doesn't require a config file. You can try turning that command off and creating a config file yourself with their reverse proxy config https://caddyserver.com/docs/caddyfile/patterns#reverse-proxy
User bddf69
Okay, if you use http (no https) with port 1337 it works 🎉 So indeed, still something wrong with Caddy
User 7043bc
Looks good.
Bot is also displayed as online.
Bot is also displayed as online.
Now the only question is what I have to do to reach the web interface.
At the moment I still get HTTP ERROR 502 resp.
ERR_SSL_PROTOCOL_ERROR at the duckdns domain with port 1337
ERR_SSL_PROTOCOL_ERROR at the duckdns domain with port 1337
I guess this has something to do with the configfile of caddy?
Only as I said, under /etc/caddy/Caddyfile I have no file or the folder caddy is not to be found under /etc.
Only as I said, under /etc/caddy/Caddyfile I have no file or the folder caddy is not to be found under /etc.
User bddf69
So it looks like Caddy is okay now, judging from what your domain is returning now. The issue is that Caddy -> CSMM is erroring now. Your CSMM logs show that error
Error [DisallowedIntents]: Privileged intent provided is not enabled or whitelisted.
You need to enable those in the Discord developer dashboard for your server

image.png
PNG • 87.2 KB
User 7043bc
I'm sorry, but no matter what I try, I can't get the csmm-worker to work.
I don't know what to look for with the worker either.
Does this have something to do with Discord?
Does this have something to do with Discord?
I have checked everything in the discord developers section.
SteamKey, Ownerid, token, client secred and cliendid. Everything is correct so far.
SteamKey, Ownerid, token, client secred and cliendid. Everything is correct so far.
The only thing I noticed in the worker logs is the following:
WARNING
You are not using https in your CSMM_HOSTNAME. This is insecure!
Please consider adding a reverse proxy to your deployment
You are not using https in your CSMM_HOSTNAME. This is insecure!
Please consider adding a reverse proxy to your deployment
In other words: Caddy still doesn't seem to run. That's why the config file has not been created yet.
I have already left the caddy logs above. I don't see any error messages or warnings, so it looks good to me.
I don't know how to proceed again.
I check the same things over and over again.
I check the same things over and over again.
Can you please tell me again what to look for?
User 7043bc
Now it says here: https://docs.csmm.app/en/CSMM/self-host/reverse-proxy.html#caddy
"Once Caddy is installed, it will have created a default config file in /etc/caddy/Caddyfile".
under "etc" I have no folder "caddy" let alone a config file. Does this mean that something is missing or caddy is not running properly yet?
User 7043bc
okay and one step further again.
Also Caddy does not give any more error messages.
Also Caddy does not give any more error messages.
User bddf69
So either you need to change the CSMM service name
OR
it already has that name but CSMM is not running
it already has that name but CSMM is not running
User bddf69
Which makes sense actually because the default name for the csmm container is
csmm-webUser bddf69
in how far this message is relevant would have to be explained to me.
It means it tried to DNS lookup
csmm and couldn't find it. 127.0.0.11:53 is the docker internal DNS serverUser 7043bc
Thank you. I am so free and post the logs here. I myself can do with it only limited what.
"lookup csmm on 127.0.0.11:53: no such host".
in how far this message is relevant would have to be explained to me.
User bddf69
or
docker-compose logs caddy would also do itUser bddf69
It's a container, so
docker logs <container id> would be a way to get those logsUser 7043bc
Yes, I changed csmm.yourdomain.com in the compose file to my duckdns domain.
How can I tell that Caddy is working? It runs under the processes, but how do I know it is working?
I can't find any logs from caddy. I have looked under "/home/csmm" and "/var/log". Where would I find the logs?

caddy.png
PNG • 53.1 KB
Sunday, April 16, 2023
User bddf69
Oh, and did you check Caddy logs for any errors
User bddf69
The Discord privileged intents error can be fixed if you go to your Discord bot dashboard and enable the intents there
User bddf69
Does Caddy work, I'm guessing no? Did you edit the
csmm.yourdomain.com part?User 7043bc
short update: so far everything looks quite good, no more "Access denied" messages.
The status of "manager_csmm-web" and "manager-db-1" is now set to "healthy".
Only the "csmm-worker" does not want to start now.
Oh and regarding Caddy, I don't have a configfile under "/etc/caddy/Caddyfile".
I have
caddy: restart: unless-stopped image: caddy ports: - 80:80 - 443:443 command: caddy reverse-proxy --to csmm:1337 --from csmm.yourdomain.com volumes: - ./caddy/config:/config/caddy:Z - ./caddy/data:/data/caddy:Z
added to the docker compose file, but still the config file is not created.
I have already deleted and recreated the docker image, but doesn't seem to have done much.
Here again some logs from the worker:
User 7043bc
it's not. Still getting some errors
User bddf69
Unless you have something running to act on it, I don't think so
Is CSMM working now?
User 7043bc
thank you very much
but now the status is displayed as "unhealthy". Does this affect anything if the status is not "healthy"?
but now the status is displayed as "unhealthy". Does this affect anything if the status is not "healthy"?
User bddf69
You inside Docker networks, you need to use the Docker DNS name of redis. 127.0.0.1 point to the local container, but redis is running in another container.
See here,
https://github.com/CatalysmsServerManager/7-days-to-die-server-manager/blob/master/.env.example.docker#L46
cache is the dns name in this casehttps://github.com/CatalysmsServerManager/7-days-to-die-server-manager/blob/master/.env.example.docker#L46
User 7043bc
the connection to the database seems to work now.
Error: A hook (
session) could not be loaded!Error: Failed to lift app: Redis connection to 127.0.0.1:6379 failed - connect ECONNREFUSED 127.0.0.1:6379 {"address": "127.0.0.1", "code": "ECONNREFUSED", "errnrror: connect ECONNREFUSED 127.0.0.1:6379\n at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1278:16)", "syscall": "connect"}
What to do here?
I followed the instructions here: https://www.digitalocean.com/community/tutorials/how-to-install-and-secure-redis-on-ubuntu-20-04
I followed the instructions here: https://www.digitalocean.com/community/tutorials/how-to-install-and-secure-redis-on-ubuntu-20-04
The password I assigned is correct.
The port is also correct. What else could be the problem?
The port is also correct. What else could be the problem?

csmmstatus.png
PNG • 39.1 KB
User bddf69
User 7043bc
But if docker creates the user for me, how would I know what to enter here:
DBSTRING=mysql2://csmm:your-db-password@db:3306/csmm
User bddf69
Making an extra user if fine though
User bddf69
Depends on the mysql version you're running, but the Docker install will automatically create the user for you
