Usually (without kubernetes, on my local machine), when I access the app it sends a get request to an API endpoint and it populates my angular app with information from there.
However, after I have uploaded the angular and the backend app to kubernetes and I access my angular app, the homepage loads but I get a 404 CORS errors from the API endpoint calls and no information is fetched so I just have a unpopulated homepage.
I have tried to use the information provided in this link but to no avail - meaning to start a chrome browser without security.
I also have added in my nginx file the information below but still doesn't work.
What information would you need to help you better understand the situation? I'm not sure what I should share.
Here is the angular app service yaml.
apiVersion: v1
kind: Service
metadata:
name: powerplant-angular-service
spec:
selector:
app: powerplant-angular
type: ClusterIP
ports:
- protocol: TCP
port: 80
P.S. I have tested the kubernetes back-end API endpoint through postman and it works as expected, so the issue isn't from that application.