This repository has been archived by the owner on Oct 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
147 additions
and
109 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
package structs | ||
|
||
type UserProvidedCredentials = map[string]string | ||
|
||
type CredentialsRDS struct { | ||
DB_Name string `json:"db_name"` | ||
Host string `json:"host"` | ||
Name string `json:"name"` | ||
Password string `json:"password"` | ||
Port string `json:"port"` | ||
Username string `json:"username"` | ||
Uri string `json:"uri"` | ||
} | ||
|
||
type CredentialsS3 struct { | ||
Uri string `json:"uri"` | ||
InsecureSkipVerify bool `json:"insecure_skip_verify"` | ||
AccessKeyId string `json:"access_key_id"` | ||
SecretAccessKey string `json:"secret_access_key"` | ||
Region string `json:"region"` | ||
Bucket string `json:"bucket"` | ||
Endpoint string `json:"endpoint"` | ||
FipsEndpoint string `json:"fips_endpoint"` | ||
AdditionalBuckets []string `json:"additional_buckets"` | ||
SyslogDrainUrl string `json:"syslog_drain_url"` | ||
VolumeMounts []string `json:"volume_mounts` | ||
} | ||
|
||
type InstanceS3 struct { | ||
Label string `json:"label"` | ||
Plan string `json:"plan"` | ||
Name string `json:"name"` | ||
Tags []string `json:"tags"` | ||
InstanceGuid string `json:"instance_guid"` | ||
InstanceName string `json:"instance_name"` | ||
BindingGuid string `json:"binding_guid"` | ||
BindingName string `json:"binding_name"` | ||
Credentials CredentialsS3 `json:"credentials"` | ||
} | ||
|
||
type InstanceRDS struct { | ||
Label string `json:"label"` | ||
Provider string `json:"provider"` | ||
Plan string `json:"plan"` | ||
Name string `json:"name"` | ||
Tags []string `json:"tags"` | ||
InstanceGuid string `json:"instance_guid"` | ||
InstanceName string `json:"instance_name"` | ||
BindingGuid string `json:"binding_guid"` | ||
BindingName string `json:"binding_name"` | ||
Credentials CredentialsRDS `json:"credentials"` | ||
SyslogDrainUrl string `json:"syslog_drain_url"` | ||
VolumeMounts string `json:"volume_mounts"` | ||
} | ||
|
||
type UserProvided struct { | ||
Label string `json:"label"` | ||
Name string `json:"name"` | ||
Tags []string `json:"tags"` | ||
InstanceGuid string `json:"instance_guid"` | ||
InstanceName string `json:"instance_name"` | ||
BindingGuid string `json:"binding_guid"` | ||
BindingName string `json:"binding_name"` | ||
Credentials map[string]string `json:"credentials"` | ||
} |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package util | ||
|
||
import "os" | ||
|
||
func getDebugLevel() string { | ||
return os.Getenv("CGOV_UTIL_DEBUG_LEVEL") | ||
} | ||
|
||
func IsDebugLevel(lvl string) bool { | ||
return getDebugLevel() == lvl | ||
} |
Oops, something went wrong.