Add logic to handle authenticating a websocket with the panel

This commit is contained in:
Dane Everitt
2019-09-08 17:40:06 -07:00
parent 806afc6ed6
commit 1899b1ab4b
4 changed files with 81 additions and 5 deletions

View File

@@ -200,6 +200,18 @@ func ReadConfiguration(path string) (*Configuration, error) {
return c, nil
}
var _config *Configuration
// Set the global configuration instance.
func Set(c *Configuration) {
_config = c
}
// Get the global configuration instance.
func Get() *Configuration {
return _config
}
// Ensures that the Pterodactyl core user exists on the system. This user will be the
// owner of all data in the root data directory and is used as the user within containers.
//