Skip to content

Commit 68fce04

Browse files
committed
merge
2 parents 73cdcdc + d7bd68d commit 68fce04

File tree

4 files changed

+15
-2
lines changed

4 files changed

+15
-2
lines changed

local/bin/sender.go renamed to local/bin/post-commit.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import (
44
"github.com/postgres-ci/hooks/git"
55

66
"bytes"
7+
"crypto/tls"
78
"encoding/json"
89
"fmt"
910
"net/http"
@@ -36,7 +37,13 @@ func main() {
3637
}
3738

3839
var client = http.Client{
40+
3941
Timeout: time.Second * 2,
42+
Transport: &http.Transport{
43+
TLSClientConfig: &tls.Config{
44+
InsecureSkipVerify: true,
45+
},
46+
},
4047
}
4148

4249
func send(commit Commit) error {

local/post-commit.sample

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ export SCHEME=http
44
export HOST=127.0.0.1:8080
55
export TOKEN=5e28989ba11491
66

7-
$(pwd)/.git/hooks/bin/sender
7+
$(pwd)/.git/hooks/bin/post-commit

server-side/bin/sender.go renamed to server-side/bin/post-receive.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import (
55

66
"bufio"
77
"bytes"
8+
"crypto/tls"
89
"encoding/json"
910
"fmt"
1011
"net/http"
@@ -59,6 +60,11 @@ func main() {
5960

6061
var client = http.Client{
6162
Timeout: time.Second * 2,
63+
Transport: &http.Transport{
64+
TLSClientConfig: &tls.Config{
65+
InsecureSkipVerify: true,
66+
},
67+
},
6268
}
6369

6470
func send(push git.Push) error {

server-side/post-receive.sample

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ export SCHEME=http
55
export HOST=127.0.0.1:8080
66
export TOKEN=5e28989ba11491
77

8-
./hooks/bin/sender
8+
./hooks/bin/post-receive

0 commit comments

Comments
 (0)