Quantcast
Channel: Active questions tagged https - Stack Overflow
Viewing all articles
Browse latest Browse all 1561

Symfony-Mercure - Docker (https)

$
0
0

Good morning,

I use the Mercure image to send notifications via Symfony.If I run everything locally, it works correctly, but if I try to deploy on a server with an associated domain, I have issues with Mercure and the SSL certificate.

My configuration is as follows:

webapp:  image: ***/nginx  networks:    - default    - reverseproxy  volumes_from:    - phpfpm  environment:    VIRTUAL_HOST: api.example.it    LETSENCRYPT_HOST: api.example.it    LETSENCRYPT_EMAIL: ***@***.it    CLIENT_MAX_BODY_SIZE: 48M  restart: unless-stoppedphpfpm:  image: image-server:latest  volumes:    - ./vendor:/app/vendor    - ./resources:/app/resources  restart: unless-stopped  environment:    MAX_UPLOAD_SIZE: 48M    POST_MAX_SIZE: 48Mmercure:  image: dunglas/mercure  environment:    SERVER_NAME: ':443'    MERCURE_URL: 'https://api.example.it/.well-known/mercure'    MERCURE_PUBLIC_URL: 'https://api.example.it/.well-known/mercure'    MERCURE_SUBSCRIBER_JWT_KEY: '***************************'    MERCURE_PUBLISHER_JWT_KEY: '***************************'    ALLOW_ANONYMOUS: 1    CORS_ALLOWED_ORIGINS: 'https://example.it'    PUBLISH_ALLOWED_ORIGINS: '*'    MERCURE_EXTRA_DIRECTIVES: |-      cors_origins "https://example.it"      anonymous    ADDR: ':443'  ports:    - '1338:443'

The error I encounter is always the following:

Dangerous site Attackers on the site you're trying to visit mighttrick you into installing software or revealing things like yourpassword, phone, or credit card number. Chrome strongly recommendsgoing back to safety. Learn more Chrome has built-in safety featuresto protect you while you browse — like Google Safe Browsing, whichrecently found phishing on the site you're trying to visit. Phishingsites pretend to be other sites to trick you.

Even sites that are normally safe are sometimes compromised byattackers. Let us know if you think there's been a mistake and thatthis site doesn't pose a danger.

Only visit this unsafe site if you're sure you understand the risks.

I have made many attempts, but I always end up with the error shown in the image.Can anyone help me? I'm surely making a mistake in the container configuration, but I can't figure out where.

On the server, I use a reverse proxy, and the image also assigns the certificate to the domain present in Nginx.

Thank you very much.

My attempts have focused on the container configuration. I tried setting the address to https://api.example.it:1338 with a port, but I don't think this is correct.

I looked through the documentation but couldn't quite understand how to resolve the issue. I believe that the domain doesn't need to be re-certified, but I could be wrong.


Viewing all articles
Browse latest Browse all 1561

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>