/express-admin-examples

Examples repository for Express Admin

Primary LanguageSQLPLMIT LicenseMIT

Express Admin Examples

This is the examples repository for Express Admin

Other locations:

Install

$ git clone https://github.com/simov/express-admin-examples
$ cd express-admin-examples
$ npm install

Create the schema and the test user

MySQL
CREATE SCHEMA `express-admin-examples` ;
CREATE USER liolio@localhost IDENTIFIED BY 'karamba' ;
GRANT ALL ON `express-admin-examples`.* TO liolio@localhost ;
PostgreSQL
create database "express-admin-examples";
-- create schema 'name'; (default: 'public')
create user liolio with password 'karamba';
grant all on database "express-admin-examples" to liolio;
-- public schema by default
grant all on schema "public" to liolio;
grant all on all tables in schema "public" to liolio;
grant all on all sequences in schema "public" to liolio;

Import the schema and the test data

# MySQL
$ mysql -p --user=root 'express-admin-examples' < fixtures/mysql/schema.sql
$ mysql -p --user=root 'express-admin-examples' < fixtures/mysql/insert.sql
# PostgreSQL
$ sudo -u postgres psql 'express-admin-examples' < fixtures/pg/schema.sql
$ sudo -u postgres psql 'express-admin-examples' < fixtures/pg/insert.sql
# SQLite
$ node fixtures/sqlite/import.js

For SQLite you need to change the path to the database inside config/sqlite/config.json

Run the Admin

# MySQL
$ admin config/mysql/
# PostgreSQL
$ admin config/pg/
# SQLite
$ admin config/sqlite/

Navigate to http://localhost:3000

Username: admin Password: 11aaAA