Angular and Spring System for homologation

0

We have a VM in the azure.

I generated the homologation build and put it on the server.

Generated the files and index.html so

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>DESIF</title>
  <base href="/">

  <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="icon" type="image/x-icon" href="favicon.ico">
</head>
<body>

  <app-root>Carregando ...</app-root>

<script type="text/javascript" src="inline.bundle.js"></script><script type="text/javascript" src="polyfills.bundle.js"></script><script type="text/javascript" src="styles.bundle.js"></script><script type="text/javascript" src="vendor.bundle.js"></script><script type="text/javascript" src="main.bundle.js"></script></body>
</html>

On the Tomcat server. in the Program Files \ Apache Software Foundation \ Tomcat 8.5 \ webapps folder, I created the dist folder.

When you enter the address: link , it goes to the correct page, loading changes the address to link , which is correct, but I thought it would be: link

If you press F5 or CTRL + F5 , it goes to TOMCAT start.

Do I have to configure something?

No Angular, I have a file that has the Server address, in case it is ** link *, so you do not have to keep changing every time you go up for approval, do you have the angle to do this automatically, for some variable?

First time I deploy.

Is there any better way?

    
asked by anonymous 20.04.2018 / 00:47

1 answer

0

I changed the Html, this part of base href="/" > for < base href="./" > , and so it worked.

But is there any other way I can do without having to change the html?

How can you make a server variable of approval, production and development, since they change, in the angular?

    
20.04.2018 / 18:51