Attempt to create "sites" folder on start (fix #32)
This commit is contained in:
parent
7ccd29bfb1
commit
401f4a89f8
5
main.go
5
main.go
@ -102,6 +102,11 @@ func main() {
|
||||
go handler(data) // Run the handler
|
||||
fmt.Fprint(w, "Received!")
|
||||
})
|
||||
// Attempt to create sites_dir
|
||||
if exists, _ := fileExists(configuration.sites_dir); !exists {
|
||||
os.Mkdir(configuration.sites_dir, 640) // Permissions are 640 (Owner: rw, Group: r, All: none)
|
||||
}
|
||||
|
||||
log.Printf("Starting Lapis Deploy on port %d...", configuration.port)
|
||||
|
||||
startAllSites() // Start all the servers
|
||||
|
Loading…
Reference in New Issue
Block a user