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

Stuck at Getting the certificate, please wait... #704

Closed
FluffyDiscord opened this issue Nov 6, 2024 · 6 comments
Closed

Stuck at Getting the certificate, please wait... #704

FluffyDiscord opened this issue Nov 6, 2024 · 6 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@FluffyDiscord
Copy link

Describe the bug
Nginx UI fails to send request to create SSL certificate if its run from Firefox.

To Reproduce
Steps to reproduce the behavior:

  1. Create new site with custom config
  2. Switch back from Advanced to Basic view
  3. Try generating SSL certificate
  4. Windows pops up and it gets stuck

Expected behavior
Certificate creates normally

Screenshots
image

Info (please complete the following information):

  • Server OS: OpenSuse Leap 15.6
  • Server Arch: x86
  • Nginx UI Version: 2.0.0-beta.39 (2) [Docker]
  • Your Browser: Firefox

Additional context
Works using Chrome.

@FluffyDiscord FluffyDiscord added the bug Something isn't working label Nov 6, 2024
@0xJacky
Copy link
Owner

0xJacky commented Nov 7, 2024

Hi @FluffyDiscord, did you run Nginx UI behind a reverse proxy?

@0xJacky
Copy link
Owner

0xJacky commented Nov 7, 2024

If so, please modify the configuration file to allow Nginx to handle WebSocket requests for Nginx UI.

server {
    listen          80;
    listen          [::]:80;

    server_name     <your_server_name>;
    rewrite ^(.*)$  https://$host$1 permanent;
}

map $http_upgrade $connection_upgrade {
    default upgrade;
    ''      close;
}

server {
    listen  443       ssl;
    listen  [::]:443  ssl;
    http2   on;

    server_name         <your_server_name>;

    ssl_certificate     /path/to/ssl_cert;
    ssl_certificate_key /path/to/ssl_cert_key;

    location / {
        proxy_set_header    Host                $host;
        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_http_version  1.1;
        proxy_set_header    Upgrade             $http_upgrade;
        proxy_set_header    Connection          $connection_upgrade;
        proxy_pass          http://127.0.0.1:9000/;
    }
}

@FluffyDiscord
Copy link
Author

No, it's not run behind reverse proxy. Also I noticed that the error I sent in screenshot happens also on Chrome, but at random. Refreshing page helps.

@Hintay
Copy link
Collaborator

Hintay commented Nov 8, 2024

Hello, can you provide the running logs of the nginx ui at the time of this issue?

@Hintay Hintay added the help wanted Extra attention is needed label Nov 8, 2024
@FluffyDiscord
Copy link
Author

Hi, there is nothing to send. It's a cors issue as mentioned before. You can see the only error on the screenshot. The request was blocked by browser apparently, so nginx doesn't even see it

@0xJacky
Copy link
Owner

0xJacky commented Nov 16, 2024

I will fix it later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
Status: Done
Development

No branches or pull requests

3 participants