feat: add release manifest and enforce certificate file verification in setupCertificate
Build and Release / release (push) Successful in 42s
Build and Release / release (push) Successful in 42s
This commit is contained in:
@@ -11,16 +11,16 @@ import (
|
|||||||
const caCertName = "firefly-go-proxy-ca.crt"
|
const caCertName = "firefly-go-proxy-ca.crt"
|
||||||
|
|
||||||
func setupCertificate(installSystemCA bool) (*tls.Certificate, error) {
|
func setupCertificate(installSystemCA bool) (*tls.Certificate, error) {
|
||||||
if !installSystemCA {
|
|
||||||
return &goproxy.GoproxyCa, nil
|
|
||||||
}
|
|
||||||
|
|
||||||
if _, err := os.Stat(caCertName); os.IsNotExist(err) {
|
if _, err := os.Stat(caCertName); os.IsNotExist(err) {
|
||||||
if err := os.WriteFile(caCertName, goproxy.GoproxyCa.Certificate[0], 0644); err != nil {
|
if err := os.WriteFile(caCertName, goproxy.GoproxyCa.Certificate[0], 0644); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if !installSystemCA {
|
||||||
|
return &goproxy.GoproxyCa, nil
|
||||||
|
}
|
||||||
|
|
||||||
absPath, err := filepath.Abs(caCertName)
|
absPath, err := filepath.Abs(caCertName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|||||||
+2
-2
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"tag": "1.2-02",
|
"tag": "1.2-03",
|
||||||
"title": "PreBuild Version 1.2 - 02"
|
"title": "PreBuild Version 1.2 - 03"
|
||||||
}
|
}
|
||||||
|
|
||||||
Reference in New Issue
Block a user