This commit is contained in:
@@ -16,11 +16,6 @@ steps:
|
|||||||
- docker build -t drone-example .
|
- docker build -t drone-example .
|
||||||
- docker rm -f drone-example
|
- docker rm -f drone-example
|
||||||
- docker run -d -p 127.241.212.77:1098:5000 --restart always --name drone-example drone-example
|
- docker run -d -p 127.241.212.77:1098:5000 --restart always --name drone-example drone-example
|
||||||
when:
|
|
||||||
event:
|
|
||||||
- promote
|
|
||||||
target:
|
|
||||||
- production
|
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
- name: docker-socket
|
- name: docker-socket
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ import (
|
|||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
r := http.NewServeMux()
|
r := http.NewServeMux()
|
||||||
r.HandleFunc("/foo", func(w http.ResponseWriter, r *http.Request) {
|
r.HandleFunc("/foo/sum", func(w http.ResponseWriter, r *http.Request) {
|
||||||
if r.Method != http.MethodGet {
|
if r.Method != http.MethodGet {
|
||||||
http.Error(w, "Method not allowed", http.StatusMethodNotAllowed)
|
http.Error(w, "Method not allowed", http.StatusMethodNotAllowed)
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user