I have an application in which the entire part of the interface is in a resource. I would like to share things. And to have a separate server for the user interface provided by gulp, for example.
So, I believe that my server should return index.html for all requests that are displayed by the client.
For example: I have a route "user /: id" that is controlled by angular routing and does not need any server. How to configure so that the server does not restart or redirect me anywhere?
Below is my security configuration (I don’t know if it is responsible for such things):
public class Application extends WebSecurityConfigurerAdapter { @Override protected void configure(HttpSecurity http) throws Exception { http.antMatcher("/**").authorizeRequests().antMatchers("/", "/login**", "/webjars/**", "/app/**", "/app.js") .permitAll().anyRequest().authenticated().and().exceptionHandling() .authenticationEntryPoint(new LoginUrlAuthenticationEntryPoint("/")).and().logout() .logoutSuccessUrl("/").permitAll().and().csrf() .csrfTokenRepository(csrfTokenRepository()).and() .addFilterAfter(csrfHeaderFilter(), CsrfFilter.class) .addFilterBefore(ssoFilter(), BasicAuthenticationFilter.class); }
source share