Skip to content

Commit

Permalink
Merge pull request #131 from Pranav-b-7/location-header-for-autopilot
Browse files Browse the repository at this point in the history
bug fix
  • Loading branch information
ramyaravi-opsmx authored Feb 5, 2021
2 parents 2e537c4 + 4a35154 commit f77fbf6
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ class AuthConfig {
.antMatchers(PermissionRevokingLogoutSuccessHandler.LOGGED_OUT_URL).permitAll()
.antMatchers('/auth/user').permitAll()
.antMatchers(HttpMethod.POST,'/autopilot/registerCanary').permitAll()
.antMatchers(HttpMethod.GET,'/autopilot/api/v2/autopilot/canaries/{id}').permitAll()
.antMatchers(HttpMethod.GET,'/autopilot/api/v1/autopilot/canaries/{id}').permitAll()
.antMatchers(HttpMethod.POST,'/autopilot/api/v1/registerCanary').permitAll()
.antMatchers(HttpMethod.POST,'/autopilot/api/v2/registerCanary').permitAll()
.antMatchers(HttpMethod.GET,'/autopilot/canaries/{id}').permitAll()
Expand Down Expand Up @@ -146,6 +148,8 @@ class AuthConfig {
.antMatchers(HttpMethod.POST,'/autopilot/api/v1/registerCanary').permitAll()
.antMatchers(HttpMethod.POST,'/autopilot/api/v2/registerCanary').permitAll()
.antMatchers(HttpMethod.GET,'/autopilot/canaries/{id}').permitAll()
.antMatchers(HttpMethod.GET,'/autopilot/api/v2/autopilot/canaries/{id}').permitAll()
.antMatchers(HttpMethod.GET,'/autopilot/api/v1/autopilot/canaries/{id}').permitAll()
.antMatchers(HttpMethod.POST,'/visibilityservice/v1/approvalGates/{id}/trigger').permitAll()
.antMatchers(HttpMethod.POST,'/visibilityservice/v2/approvalGates/{id}/trigger').permitAll()
.antMatchers(HttpMethod.GET,'/visibilityservice/v2/approvalGateInstances/{id}/status').permitAll()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

package com.netflix.spinnaker.gate.controllers

import com.google.gson.Gson
import com.netflix.spinnaker.gate.config.ServiceConfiguration
import com.netflix.spinnaker.gate.model.ApprovalGateTriggerResponseModel
import com.netflix.spinnaker.gate.model.RegisterCanaryResponseModel
Expand Down Expand Up @@ -64,6 +65,8 @@ class OpsmxAutopilotController {
@Autowired
OpsmxAutopilotService opsmxAutopilotService

Gson gson = new Gson()

@ApiOperation(value = "Endpoint for autopilot rest services")
@RequestMapping(value = "/{type}", method = RequestMethod.GET)
Object getAutoResponse1(@PathVariable("type") String type) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,12 @@ package com.netflix.spinnaker.gate.model
class RegisterCanaryResponseModel {

private Integer canaryId;

Integer getCanaryId() {
return canaryId
}

void setCanaryId(Integer canaryId) {
this.canaryId = canaryId
}
}

0 comments on commit f77fbf6

Please sign in to comment.