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

Local env. communication between two dockerized API Platform apps

$
0
0

I have to repos, both of them having two API Platform based apps:

Now, both of them are dockerized with the default Docker configuration that API Platform is shipping. I have the following scenario:

  • App1, inside its own container (C1) needs to send a request to App2 that lives inside its own container (C2).

I've managed to crate a bridge between them, that looks similar to this (following this article: https://medium.com/@murilolivorato/connecting-two-laravel-projects-built-in-two-docker-compose-environments-1a979e64f332):

compose.yaml (App1) inside C1:

services:  php:    [...]    networks:      - app1_network      - app2_app1_network  networks:    app2_app1_network:      external: true    app1_network:

compose.yaml (App2) inside C2:

services:  php:    [...]    networks:      - app2_network      - app1_network  networks:    app1_network:      driver: bridge    app2_network:

Now, these configurations seems to work. I can configure App1 to send a request to "https://<app2-container-name/api/v1/".

But the next bump I've hit is realted to HTTPS.API Platform framework is exposing all endpoints (even locally), over HTTPS. And when I try to send a request from C1 to C2, using the configuration above, I hit the following error:

OpenSSL/3.0.13: error:0A000438:SSL routines::tlsv1 alert internal error for "https://<app-2-container-name>/api/v1/<some-endpoint>".

I'm kinda stuck at this point.

  1. Does anyone have any idea how can I fix this? I'm not too versed into dev-ops stuff and I haven't played too much with HTTPS issues.
  2. Does anyone knows how to disable HTTPS on local environment, for API Platform? I cannot seem to find out how in the framework documentation.

Initially I've tried to enable communication between C1 and C2, following the specified article. But after doing that, I get the OpenSSL/3.0.13: error:0A000438:SSL routines::tlsv1 alert internal error for "https://<app-2-container-name>/api/v1/<some-endpoint".

I've also tried to disable HTTPS in API Platform, on my local environment, but with no luck. Each request to HTTP, is redirected somewhere to HTTPS.


Viewing all articles
Browse latest Browse all 1519

Trending Articles



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