update to golang 1.20 (#9690)
update alpine and golang remove nano update go modules remove need for openssl external cli fix stale Signed-off-by: James Strong <james.strong@chainguard.dev>
This commit is contained in:
parent
ddcfaecb3c
commit
66a760794f
24 changed files with 59 additions and 40 deletions
|
|
@ -1,7 +1,7 @@
|
|||
ARG E2E_BASE_IMAGE
|
||||
FROM ${E2E_BASE_IMAGE} AS BASE
|
||||
|
||||
FROM alpine:3.16.2
|
||||
FROM alpine:3.17.2
|
||||
|
||||
RUN apk add -U --no-cache \
|
||||
ca-certificates \
|
||||
|
|
|
|||
|
|
@ -19,9 +19,9 @@ package annotations
|
|||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"os/exec"
|
||||
"regexp"
|
||||
"strings"
|
||||
"time"
|
||||
|
|
@ -899,7 +899,8 @@ http {
|
|||
// Auth error
|
||||
|
||||
func buildSecret(username, password, name, namespace string) *corev1.Secret {
|
||||
out, err := exec.Command("openssl", "passwd", "-crypt", password).CombinedOutput()
|
||||
//out, err := exec.Command("openssl", "passwd", "-crypt", password).CombinedOutput()
|
||||
out, err := bcrypt.GenerateFromPassword([]byte(password), 14)
|
||||
encpass := fmt.Sprintf("%v:%s\n", username, out)
|
||||
assert.Nil(ginkgo.GinkgoT(), err)
|
||||
|
||||
|
|
@ -917,7 +918,8 @@ func buildSecret(username, password, name, namespace string) *corev1.Secret {
|
|||
}
|
||||
|
||||
func buildMapSecret(username, password, name, namespace string) *corev1.Secret {
|
||||
out, err := exec.Command("openssl", "passwd", "-crypt", password).CombinedOutput()
|
||||
//out, err := exec.Command("openssl", "passwd", "-crypt", password).CombinedOutput()
|
||||
out, err := bcrypt.GenerateFromPassword([]byte(password), 14)
|
||||
assert.Nil(ginkgo.GinkgoT(), err)
|
||||
|
||||
return &corev1.Secret{
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@ package settings
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
"net/http"
|
||||
"os/exec"
|
||||
"strings"
|
||||
|
||||
"github.com/onsi/ginkgo/v2"
|
||||
|
|
@ -147,7 +147,8 @@ func buildBasicAuthIngressWithSecondPath(host, namespace, secretName, pathName s
|
|||
}
|
||||
|
||||
func buildSecret(username, password, name, namespace string) *corev1.Secret {
|
||||
out, err := exec.Command("openssl", "passwd", "-crypt", password).CombinedOutput()
|
||||
//out, err := exec.Command("openssl", "passwd", "-crypt", password).CombinedOutput()
|
||||
out, err := bcrypt.GenerateFromPassword([]byte(password), 14)
|
||||
assert.Nil(ginkgo.GinkgoT(), err, "creating password")
|
||||
|
||||
encpass := fmt.Sprintf("%v:%s\n", username, out)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue