Update output when booting

This commit is contained in:
Dane Everitt 2020-04-17 14:32:09 -07:00
parent 4279fa510e
commit 9e0cacc076
No known key found for this signature in database
GPG Key ID: EEA66103B3D71F53
2 changed files with 12 additions and 2 deletions

View File

@ -81,7 +81,7 @@ func rootCmdRun(*cobra.Command, []string) {
panic(err) panic(err)
} }
zap.S().Infof("using configuration from path: %s", configPath) zap.S().Infof("using configuration from path: %s", c.GetPath())
if c.Debug { if c.Debug {
zap.S().Debugw("running in debug mode") zap.S().Debugw("running in debug mode")
zap.S().Infow("certificate checking is disabled") zap.S().Infow("certificate checking is disabled")
@ -264,4 +264,9 @@ func printLogo() {
fmt.Println(` \___/\___/___/___/___/___ /______/`) fmt.Println(` \___/\___/___/___/___/___ /______/`)
fmt.Println(` /_______/ v` + system.Version) fmt.Println(` /_______/ v` + system.Version)
fmt.Println() fmt.Println()
fmt.Println(`Website: https://pterodactyl.io`)
fmt.Println(`Source: https://github.com/pterodactyl/wings`)
fmt.Println()
fmt.Println(`Copyright © 2018 - 2020 Dane Everitt & Contributors`)
fmt.Println()
} }

View File

@ -237,6 +237,11 @@ func GetJwtAlgorithm() *jwt.HMACSHA {
return _jwtAlgo return _jwtAlgo
} }
// Returns the path for this configuration file.
func (c *Configuration) GetPath() string {
return c.path
}
// Ensures that the Pterodactyl core user exists on the system. This user will be the // 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. // owner of all data in the root data directory and is used as the user within containers.
// //
@ -376,7 +381,7 @@ func (c *Configuration) WriteToDisk() error {
c.writeLock.Lock() c.writeLock.Lock()
defer c.writeLock.Unlock() defer c.writeLock.Unlock()
if err := ioutil.WriteFile(c.path, b, 0644); err != nil { if err := ioutil.WriteFile(c.GetPath(), b, 0644); err != nil {
return err return err
} }