I am trying to install AMP (From Cube Coders)
To run a minecraft server
I am running on CachOS with certbot 5.6.0-1 and same for certbot-nginx
So I did have this working a month or two ago, we fixed this issue back then somehow and can't remember how anymore and after a few days of trying we have given up)
So the cloudflare side and my router are the same just anything on the OS side got uninstalled
I did go and double check
To replicate
sudo su -
bash <(curl -fsSL getamp.sh)
Setup with correct settings yada yada
Let it run and....
Could not automatically find a matching server block for panel.kubenblisk.com. Set the server_name directive to use the Nginx installer.
[Error/9] Certbot failed with code 1
Tried setting up the files we did last time
Yes 80, 8080 and 443 and forwarded
So no idea how to fix this issue and I have looked on 50 websites
Before we get into that do you have it working?
Because I see a cert issued today for that domain. Also one issued May24 and some before that.
I cannot reach that domain now. I only get timeouts for HTTP and HTTPS so perhaps you are now firewalled or offline.
No sense debugging a problem you've already solved. Let us know the current status
Nope still not working, so I added include /etc/nginx/conf.d/minecraft.conf to the Nginx config now I get another error, idk if this is progress or not
.
The nginx plugin is not working; there may be problems with your existing configuration.
The error was: MisconfigurationError('Error while running nginx -c /etc/nginx/nginx.conf -t.\n\n2026/06/03 06:54:48 [emerg] 17976#17976: "server" directive is not allowed here in /etc/nginx/conf.d/minecraft.conf:1\nnginx: configuration file /etc/nginx/nginx.conf test failed\n')
[Error/9] Certbot failed with code 1
That is a fundamental error in the nginx config. Because it is "emerg" level your nginx cannot even start. This needs fixing first.
Please post contents of that minecraft.conf file
Note: running sudo nginx -t will give you the same error Certbot is getting. Using its --nginx option means Certbot will reload nginx so it validates your config with this command.
server {
server_name panel.kubenblisk.com;
location / {
proxy_pass http://127.0.0.1:8080/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
include /etc/nginx/conf.d/*.conf;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
You put that file in that conf.d. Yet, you also have an include of this within that conf. That is a circular reference.
I wish I was smart enough to know what that means so can you put it in laymans terms please 
Well, I probably can but this forum isn't the best place for helping you setup nginx.
You might try the help site for AMP or even one for CachyOS
Once you have nginx running and able to process HTTP requests from the public internet you can try Certbot again. Then come back with any problems.
While we often help people fix common mistakes in their server config we aren't an all-purpose site for setting up servers.
I already posted on CubeCoders forums and Discord... I got told to ask here so guess I am SOL
Yes, well, the error in the first post might look like a compatibility issue with Certbot. Perhaps that is why they sent you here. And, you were right to make a server block for the server_name in question. You just did it wrong. I think you need to educate yourself more about how nginx works and is configured. If you had it setup right at the start the --nginx option would have worked straight away and you wouldn't even need to be here 
Perhaps someone else here will help you work through that. I think this particular nginx problem is just the first of a number of issues you'll need help with. I don't have that time tonight and probably not soon. Which is why I suggested what I did.
So I removed the second line and I am back to issue one
"Could not automatically find a matching server block for panel.kubenblisk.com. Set the server_name directive to use the Nginx installer.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.
[Error/6] Certbot failed with code 1
To add on what the last guy said about "This not being the place" I have no clue but the module Literally links me to ask here when it fails so...
You can put back the second line, the issue is the line
Try removing it.
The issue is that it's including itself so you effectively end up with
server {
server_name panel.kubenblisk.com;
location / {
proxy_pass http://127.0.0.1:8080/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
server {
server_name panel.kubenblisk.com;
location / {
proxy_pass http://127.0.0.1:8080/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
include /etc/nginx/conf.d/*.conf;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
So the second sever block is inside a location block which is invalid and causing the error message.
Okay I removed include /etc/nginx/conf.d/*.conf; like you said
Re added include /etc/nginx/conf.d/minecraft.conf;
Back to this error
The nginx plugin is not working; there may be problems with your existing configuration.
The error was: MisconfigurationError('Error while running nginx -c /etc/nginx/nginx.conf -t.\n\n2026/06/03 12:31:26 [emerg] 15066#15066: "server" directive is not allowed here in /etc/nginx/conf.d/minecraft.conf:1\nnginx: configuration file /etc/nginx/nginx.conf test failed\n')
[Error/9] Certbot failed with code 1
Failed to configure nginx.
That include is already performed in another file, you do not need any include directives in /etc/nginx/conf.d/minecraft.conf. Is there a reason why you added the include directive?
I have read about 30 forum posts over 8 forums and a few tech threads and so on, at some point one of them would have suggested it. Yeah I know that sounds dumb. I have just been trying what ever I can find pretty much to see what works or what doesn't and why.
Do you want me to remove the include part and leave the rest of that line?
Remove the whole line including the path.
Okay done that
First to re mention, we had this working before somehow, we also tried remembering what all we did last time to get it to work and re apply that
Also back to the first error again
Could not automatically find a matching server block for panel.kubenblisk.com. Set the server_name directive to use the Nginx installer.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.
[Error/6] Certbot failed with code 1
Well its Error/6 instead of /9 now... idk if that means anything
Remove the minecraft.conf
Rebulid the Nginx conf to this
#user http;
worker_processes 1;
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#pid logs/nginx.pid;
Load all installed modules
include modules.d/*.conf;
events {
worker_connections 4096;
}
http {
include mime.types;
default_type application/octet-stream;
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';
#access_log logs/access.log main;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
#gzip on;
include conf.d/*.conf;
}