So when I try to use the host network (local machine) and then make the ports accessible for my APIs to be tested, it doesn’t make them accessible. Why is this so? What should the ideal solution to this problem? Do I have to run in my local Kubernetes to achieve this or is there some other way I can do without Kubernetes?
Aparently, I am using a mac and seems there is no support for Mac when using host as network. Is there any workaround for this like creating a network myself and anyway to expose that network to my localhost? As for your question of expose, yes I am exposing it. Here is my dockerfile:
FROM ubuntu:latest
RUN apt-get -y update && apt-get -y upgrade
RUN apt-get -y install openjdk-8-jdk
RUN mkdir -p /app/build
COPY ./build /app/build
EXPOSE 8071
RUN chmod +x /app/build/install/boringssl/bin/hello-world-tls-server
CMD ["/app/build/install/boringssl/bin/hello-world-tls-server"]