diff options
author | Emile <hanemile@protonmail.com> | 2019-11-07 13:40:31 +0100 |
---|---|---|
committer | Emile <hanemile@protonmail.com> | 2019-11-07 13:40:31 +0100 |
commit | d5b4b45e883d605a6443422b9c956308d64e969e (patch) | |
tree | 32f89aec1a924fda9d614a173e35cafeca133ce3 /src | |
parent | c4fccaf157ec39cebbb6c338deab7a6a3a3e6681 (diff) |
getChallenges
Diffstat (limited to 'src')
-rw-r--r-- | src/companion.go | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/companion.go b/src/companion.go index 8852dfa..df6affb 100644 --- a/src/companion.go +++ b/src/companion.go @@ -13,10 +13,15 @@ import ( "net/http" ) +func newCompanion(w http.ResponseWriter, r *http.Request) { + fmt.Fprintf(w, "%s", "newCompanion") +} + // getChallenges returns some json containing a list of all challenges // // .../api/companion/getChallenges func getChallenges(w http.ResponseWriter, r *http.Request) { + // get a list of all challenges from the database challenges := dbGetAllChallenges() var strippedChallenges []StrippedChallenge @@ -53,7 +58,7 @@ func getChallenges(w http.ResponseWriter, r *http.Request) { // // returns a list of all running containers within the uuid context func getRunningContainers(w http.ResponseWriter, r *http.Request) { - + fmt.Fprintf(w, "%s", "getRunningContainers") } // startContainer starts a challenge container @@ -65,7 +70,7 @@ func getRunningContainers(w http.ResponseWriter, r *http.Request) { // // DEFDEFDEF is the uuid of the challenge func startContainer(w http.ResponseWriter, r *http.Request) { - + fmt.Fprintf(w, "%s", "startContainer") } // stopContainer stops one of the challenge containers @@ -77,5 +82,5 @@ func startContainer(w http.ResponseWriter, r *http.Request) { // // DEFDEFDEF is the uuid of the challenge func stopContainer(w http.ResponseWriter, r *http.Request) { - + fmt.Fprintf(w, "%s", "stopContainer") } |