mirror of
https://github.com/khuedoan/homelab.git
synced 2024-12-22 21:24:52 +07:00
test: do not skip TLS verify in production
The sandbox will set INSECURE_SKIP_VERIFY=true in the future.
This commit is contained in:
parent
0ceb426cd5
commit
d6d1cd41d5
@ -3,6 +3,7 @@ package test
|
||||
import (
|
||||
"crypto/tls"
|
||||
"fmt"
|
||||
"os"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@ -40,7 +41,7 @@ func TestSmoke(t *testing.T) {
|
||||
|
||||
// Setup a TLS configuration, ignore the certificate because we may not use cert-manager (like the sandbox environment)
|
||||
tlsConfig := tls.Config{
|
||||
InsecureSkipVerify: true,
|
||||
InsecureSkipVerify: os.Getenv("INSECURE_SKIP_VERIFY") != "",
|
||||
}
|
||||
|
||||
// Test the endpoint, this will only fail if we timeout waiting for the service to return a 200 response
|
||||
|
Loading…
Reference in New Issue
Block a user