version: ‘3’
services:
frontend:
image: iqbalcodes6602/occ-frontend:latest
container_name: frontend
ports:
– “3000:3000”
stdin_open: true
tty: true
depends_on:
– backend
networks:
– app-net
environment:
– REACT_APP_BACKEND_URL=http://backend:5000/runcode/
backend:
image: iqbalcodes6602/occ-backend:latest
container_name: backend
ports:
– “5000:5000”
networks:
– app-net
networks:
app-net:
driver: bridge
when i run docker compose up locally it works fine, but when i deploy it in Azure app serice through docker compose it doesn’t work it gives mixed content error,
App.js:29 Mixed Content: The page at ‘https://.azurewebsites.net/’ was loaded over HTTPS, but requested an insecure resource ‘[http://backend:5000/runcode/’. This request has been blocked; the content must be served over HTTPS.]
i have somequestion-
-
when i deploy it azure give me default domain going to which i can acces my react frontend how can i access the backend
-
how to connect the frontend and backend containers
-
tried changing the backend url to same as the domain got the network error
-
tried changing ports
-
when i tried backedn url to be https://.azurewebsites.net:5000/ i got time out error
Iqbal is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.