6.4 KiB
generate
import "github.com/Akilan1999/p2p-rendering-computation/config/generate"
Index
- func Copy(src, dst string) error
- func CreateIPTableFolderStructure() (err error)
- func FileExists(path string) (bool, error)
- func GenerateCertificate() error
- func GenerateClientTrackContainers() (err error)
- func GenerateDockerFiles() (err error)
- func GenerateFiles(rootNodes ...p2p.IpAddress) (err error)
- func GenerateIPTableFile(rootNodes []p2p.IpAddress) (err error)
- func GeneratePluginDirectory() (err error)
- func GetPathP2PRC() (string, error)
- func MakeSSHKeyPair(pubKeyPath, privateKeyPath string) error
- func SetDefaults(envName string, forceDefault bool, CustomConfig interface{}, NoBoilerPlate bool, ConfigUpdate ...*config.Config) (*config.Config, error)
- func SetEnvName(EnvName string) error
- func String(length int) string
- func StringWithCharset(length int, charset string) string
- type AuthorizedKey
func Copy
func Copy(src, dst string) error
Copy the src file to dst. Any existing file will be overwritten and will not copy file attributes. Source: https://stackoverflow.com/questions/21060945/simple-way-to-copy-a-file
func CreateIPTableFolderStructure
func CreateIPTableFolderStructure() (err error)
CreateIPTableFolderStructure Create folder structure for IPTable
func FileExists
func FileExists(path string) (bool, error)
FileExists exists returns whether the given file or directory exists source: https://stackoverflow.com/questions/10510691/how-to-check-whether-a-file-or-directory-exists
func GenerateCertificate
func GenerateCertificate() error
func GenerateClientTrackContainers
func GenerateClientTrackContainers() (err error)
func GenerateDockerFiles
func GenerateDockerFiles() (err error)
GenerateDockerFiles Generate default docker files
func GenerateFiles
func GenerateFiles(rootNodes ...p2p.IpAddress) (err error)
GenerateFiles Generates all the files needed to setup P2PRC
func GenerateIPTableFile
func GenerateIPTableFile(rootNodes []p2p.IpAddress) (err error)
GenerateIPTableFile Generates the IPTable file with the appropirate root node
func GeneratePluginDirectory
func GeneratePluginDirectory() (err error)
GeneratePluginDirectory Generates plugin directory structure
func GetPathP2PRC
func GetPathP2PRC() (string, error)
GetPathP2PRC Getting P2PRC Directory from environment variable
func MakeSSHKeyPair
func MakeSSHKeyPair(pubKeyPath, privateKeyPath string) error
MakeSSHKeyPair make a pair of public and private keys for SSH access. Public key is encoded in the format for inclusion in an OpenSSH authorized_keys file. Private Key generated is PEM encoded source: https://gist.github.com/goliatone/e9c13e5f046e34cef6e150d06f20a34c
func SetDefaults
func SetDefaults(envName string, forceDefault bool, CustomConfig interface{}, NoBoilerPlate bool, ConfigUpdate ...*config.Config) (*config.Config, error)
SetDefaults This function to be called only during a make install
func SetEnvName
func SetEnvName(EnvName string) error
SetEnvName Sets the environment name This is to ensure that the Path of your project is detected from your environment variable This is useful when extending the use case of P2PRC
func String
func String(length int) string
func StringWithCharset
func StringWithCharset(length int, charset string) string
type AuthorizedKey
AuthorizedKey struct represents the structure of an authorized key
type AuthorizedKey struct {
Username string
Key string
}
Generated by gomarkdoc