Add deployment history endpoint
This commit is contained in:
@@ -0,0 +1,21 @@
|
|||||||
|
package com.litoralregas.openvpn.deployment;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/deployments")
|
||||||
|
public class DeploymentController {
|
||||||
|
|
||||||
|
private final DeploymentRepository repository;
|
||||||
|
|
||||||
|
public DeploymentController(DeploymentRepository repository) {
|
||||||
|
this.repository = repository;
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping
|
||||||
|
public List<Deployment> getAll() {
|
||||||
|
return repository.findAll();
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user