1

I created two container boleto_api and boleto_web the first is written in ExpressJS and the last is a VueJS application.

Created docker network named boleto and from that I started the containers.. If I ping :ping boleto_api inside container boleto_web I have successful

PING boleto_api (172.21.0.2) 56(84) bytes of data.
64 bytes from boleto_api.boleto (172.21.0.2): icmp_seq=1 ttl=64 time=0.105 ms
64 bytes from boleto_api.boleto (172.21.0.2): icmp_seq=2 ttl=64 time=0.091 ms

But in Fetch API inside VueJS

GET http://boleto_api:3030/pessoas/buscar/11532324723 net::ERR_NAME_NOT_RESOLVED

Part of code:

fetch('http://boleto_api:3030/pessoas/buscar/'+this.$store.state.cpf)
             .then(response => response.json())
             .then(data => {
                this.dadosCliente = data
                this.show = false;
             });

I dont have sure if the frontend (VueJs) will be successful to do it, if not, how to proceeded ?

3
  • This same question got asked yesterday. Is there some course going on or something? Commented Nov 10, 2020 at 23:21
  • not that I know. Commented Nov 10, 2020 at 23:25
  • I got to solve this reading this article medium.com/bb-tutorials-and-thoughts/…. for who still with thar question! Commented Nov 12, 2020 at 16:39

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.