mirror of
https://github.com/Cernobor/oko-server.git
synced 2025-02-24 08:27:17 +00:00
fix cmdline flags, fix initdb script
* Actually parse the command line flags. * Remove CASCADE from drop table.
This commit is contained in:
parent
38318ca654
commit
862350b875
3
.gitignore
vendored
3
.gitignore
vendored
@ -35,4 +35,5 @@ go.work
|
|||||||
.nfs*
|
.nfs*
|
||||||
|
|
||||||
# Project-specific
|
# Project-specific
|
||||||
oko-server
|
oko-server
|
||||||
|
*.sqlite*
|
2
main.go
2
main.go
@ -16,6 +16,8 @@ func main() {
|
|||||||
tilepackFileArg := flag.String("tilepack", "", "File that will be sent to clients when they request a tile pack. Required.")
|
tilepackFileArg := flag.String("tilepack", "", "File that will be sent to clients when they request a tile pack. Required.")
|
||||||
apkFileArg := flag.String("apk", "", "APK file with the client app. If not specified, no APK will be available (404).")
|
apkFileArg := flag.String("apk", "", "APK file with the client app. If not specified, no APK will be available (404).")
|
||||||
|
|
||||||
|
flag.Parse()
|
||||||
|
|
||||||
s := server.New(*dbFileArg, *tilepackFileArg, *apkFileArg)
|
s := server.New(*dbFileArg, *tilepackFileArg, *apkFileArg)
|
||||||
|
|
||||||
sigs := make(chan os.Signal, 1)
|
sigs := make(chan os.Signal, 1)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
DROP TABLE IF EXISTS users CASCADE;
|
DROP TABLE IF EXISTS users;
|
||||||
CREATE TABLE IF NOT EXISTS users (
|
CREATE TABLE IF NOT EXISTS users (
|
||||||
id integer PRIMARY KEY AUTOINCREMENT,
|
id integer PRIMARY KEY AUTOINCREMENT,
|
||||||
name text NOT NULL UNIQUE
|
name text NOT NULL UNIQUE
|
||||||
|
Loading…
Reference in New Issue
Block a user