This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"bufio" | |
"fmt" | |
"log" | |
"os" | |
"github.com/google/uuid" | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
kubectl --context=dev-aws -n customer-platform port-forward cockroachdb-1 26257:26257 & | |
kubectl --context=dev-aws -n customer-platform exec -ti cockroachdb-1 cat /cockroach/cockroach-certs/node.key >/tmp/node.key | |
kubectl --context=dev-aws -n customer-platform exec -ti cockroachdb-1 cat /cockroach/cockroach-certs/node.crt >/tmp/node.crt | |
chmod 600 /tmp/node.crt /tmp/node.key | |
PGSSLCERT=/tmp/node.crt PGSSLKEY=/tmp/node.key PGCLIENTENCODING=utf8 psql -w "postgresql://root@localhost:26257/itemdb?sslmode=require" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"bytes" | |
"context" | |
"encoding/json" | |
"fmt" | |
"io" | |
"log" | |
"os" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tlsresettest | |
import ( | |
"crypto/tls" | |
"io" | |
"io/ioutil" | |
"net" | |
"strings" | |
"testing" | |
) |