diff --git a/.gitignore b/.gitignore index 55371e5..b9c6354 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ node_modules -.vscode \ No newline at end of file +.vscode +*.acebase diff --git a/README.md b/README.md index c34927d..90e5080 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,20 @@ This repository is to setup an http endpoint for a local AceBase database instance. See [AceBase](https://www.npmjs.com/package/acebase) for more information about AceBase databases and usage. +![AceBase server webmanager](./img/acebase-webmanager.png) + +![AceBase server Swagger UI](./img/acebase-swagger-ui.png) + ## Getting started Install the *acebase-server* npm package: ```npm install acebase-server``` ([github](https://github.com/appy-one/acebase-server), [npm](https://www.npmjs.com/package/acebase-server)) +To test running an AceBase server with authentication on localhost:3000, execute the following commands +* `cd ./node_modules/acebase-server` +* `npm run test` +* Open [http://localhost:3000](http://localhost:3000) in your browser. To sign into the webmanager, use db name `default`, username `admin` and the generated password displayed in your console output. The webmanager allows browsing your database content and performing updates. +* Open [http://localhost:3000/docs](http://localhost:3000/docs) to open the Swagger UI that is enabled in development mode. All REST API methods are documented and can be executed here. + ## Creating an AceBase server To launch an AceBase webserver using default settings diff --git a/img/acebase-swagger-ui.png b/img/acebase-swagger-ui.png new file mode 100644 index 0000000..dfe10e2 Binary files /dev/null and b/img/acebase-swagger-ui.png differ diff --git a/img/acebase-webmanager.png b/img/acebase-webmanager.png new file mode 100644 index 0000000..e9b103a Binary files /dev/null and b/img/acebase-webmanager.png differ diff --git a/package.json b/package.json index 456c2a9..d11beb3 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "private": false, "repository": "github:appy-one/acebase-server", "scripts": { - "start": "node dist/esm/start.js DBNAME=default DBPATH=.. HOST=localhost PORT=3000 TXLOG=1 AUTH=1", + "start": "node dist/esm/start.js DBNAME=default DBPATH=. HOST=localhost PORT=3000 TXLOG=1 AUTH=1", "test": "set NODE_ENV=development && npm run start", "build": "npm run build:clean && npm run build:esm && npm run build:cjs && npm run build:packages && echo Done!", "build:clean": "rm -fr dist/*",