Skip to content
Snippets Groups Projects
Commit 0940fc51 authored by Lukas Malte Monnerjahn's avatar Lukas Malte Monnerjahn
Browse files

OZG-4717 OZG-5110 Rename environment endpoint

parent 93d997af
Branches
Tags
No related merge requests found
......@@ -9,12 +9,12 @@ import org.springframework.web.bind.annotation.RestController;
import de.ozgcloud.admin.RootController;
import lombok.RequiredArgsConstructor;
@RestController
@RestController("ozgCloudEnvironmentController")
@RequiredArgsConstructor
@RequestMapping(FrontendEnvironmentController.PATH)
public class FrontendEnvironmentController {
static final String PATH = "/api/frontendEnvironment"; // NOSONAR
static final String PATH = "/api/environment"; // NOSONAR
private final ProductionProperties environmentProperties;
......
......@@ -53,7 +53,7 @@ public class SecurityConfiguration {
http.exceptionHandling(eh -> eh.authenticationEntryPoint(authenticationEntryPoint));
http.authorizeHttpRequests(requests -> requests
.requestMatchers(HttpMethod.GET, "/api/frontendEnvironment").permitAll()
.requestMatchers(HttpMethod.GET, "/api/environment").permitAll()
.requestMatchers("/api").authenticated()
.requestMatchers("/api/**").authenticated()
.requestMatchers("/actuator").permitAll()
......
......@@ -67,7 +67,7 @@ class SecurityConfigurationITCase {
@SneakyThrows
@ParameterizedTest
@ValueSource(strings = {
"/api/frontendEnvironment",
"/api/environment",
"/configserver/name/profile"
})
void shouldAllow(String path) {
......@@ -145,7 +145,7 @@ class SecurityConfigurationITCase {
@SneakyThrows
@ParameterizedTest
@ValueSource(strings = {
"/api/frontendEnvironment",
"/api/environment",
"/configserver/name/profile",
"/api", "/api/configuration", "/api/configuration/param",
})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment