mirror of
https://github.com/gravitl/netmaker.git
synced 2025-11-10 16:50:46 +08:00
merge conflicts resolved
This commit is contained in:
parent
9e0038f39c
commit
d0646392b3
1 changed files with 14 additions and 11 deletions
|
|
@ -451,15 +451,9 @@ func authenticateHost(response http.ResponseWriter, request *http.Request) {
|
||||||
response.Write(successJSONResponse)
|
response.Write(successJSONResponse)
|
||||||
}
|
}
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
// swagger:route POST /api/hosts/{hostid}/signalpeer signalPeer
|
// swagger:route POST /api/hosts/{hostid}/signalpeer signalPeer
|
||||||
//
|
//
|
||||||
// send signal to peer.
|
// send signal to peer.
|
||||||
=======
|
|
||||||
// swagger:route POST /api/hosts/keys host updateAllKeys
|
|
||||||
//
|
|
||||||
// Update keys for a network.
|
|
||||||
>>>>>>> 6abbf075e061ffe58c35b3e75493ba5ffa175022
|
|
||||||
//
|
//
|
||||||
// Schemes: https
|
// Schemes: https
|
||||||
//
|
//
|
||||||
|
|
@ -467,8 +461,7 @@ func authenticateHost(response http.ResponseWriter, request *http.Request) {
|
||||||
// oauth
|
// oauth
|
||||||
//
|
//
|
||||||
// Responses:
|
// Responses:
|
||||||
<<<<<<< HEAD
|
// 200: signal
|
||||||
// 200: nodeResponse
|
|
||||||
func signalPeer(w http.ResponseWriter, r *http.Request) {
|
func signalPeer(w http.ResponseWriter, r *http.Request) {
|
||||||
var params = mux.Vars(r)
|
var params = mux.Vars(r)
|
||||||
hostid := params["hostid"]
|
hostid := params["hostid"]
|
||||||
|
|
@ -522,8 +515,19 @@ func signalPeer(w http.ResponseWriter, r *http.Request) {
|
||||||
}
|
}
|
||||||
w.WriteHeader(http.StatusOK)
|
w.WriteHeader(http.StatusOK)
|
||||||
json.NewEncoder(w).Encode(signal)
|
json.NewEncoder(w).Encode(signal)
|
||||||
=======
|
}
|
||||||
// 200: networkBodyResponse
|
|
||||||
|
// swagger:route POST /api/hosts/keys host updateAllKeys
|
||||||
|
//
|
||||||
|
// Update keys for a network.
|
||||||
|
//
|
||||||
|
// Schemes: https
|
||||||
|
//
|
||||||
|
// Security:
|
||||||
|
// oauth
|
||||||
|
//
|
||||||
|
// Responses:
|
||||||
|
// 200: nodeResponse
|
||||||
func updateAllKeys(w http.ResponseWriter, r *http.Request) {
|
func updateAllKeys(w http.ResponseWriter, r *http.Request) {
|
||||||
var errorResponse = models.ErrorResponse{}
|
var errorResponse = models.ErrorResponse{}
|
||||||
w.Header().Set("Content-Type", "application/json")
|
w.Header().Set("Content-Type", "application/json")
|
||||||
|
|
@ -588,5 +592,4 @@ func updateKeys(w http.ResponseWriter, r *http.Request) {
|
||||||
}()
|
}()
|
||||||
logger.Log(2, r.Header.Get("user"), "updated key on host", host.Name)
|
logger.Log(2, r.Header.Get("user"), "updated key on host", host.Name)
|
||||||
w.WriteHeader(http.StatusOK)
|
w.WriteHeader(http.StatusOK)
|
||||||
>>>>>>> 6abbf075e061ffe58c35b3e75493ba5ffa175022
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue