Skip to content

Commit 573d586

Browse files
committed
Updated docs and added setup bson for MongoDB
1 parent 94ef42a commit 573d586

File tree

5 files changed

+24
-3
lines changed

5 files changed

+24
-3
lines changed

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,22 @@ Documentation is located at http://benedmunds.com/ion_auth/
1616
Just copy the files from this package to the correspoding folder in your
1717
application folder. For example, copy Ion_auth/config/ion_auth.php to
1818
system/application/config/ion_auth.php.
19+
20+
##Relational DB Setup
1921
Then just run the appropriate SQL file (if you're using migrations you can
2022
get the migrations from JD here:
21-
https://github.com/iamfiscus/codeigniter-ion-auth-migration).
23+
https://github.com/iamfiscus/codeigniter-ion-auth-migration).
24+
25+
##MongoDB Setup
26+
Integrate the following projects to enable MongoDB support in CodeIgniter:
27+
28+
CodeIgniter MongoDB Active Record Library - http://github.com/alexbilbie/codeigniter-mongodb-library/tree/v2
29+
CodeIgniter MongoDB Session Library - http://github.com/sepehr/ci-mongodb-session
30+
31+
Set $config['use_mongodb'] = TRUE; in the config file and then run the following command:
32+
33+
$ mongorestore sql/mongo
34+
2235

2336
###Usage
2437
In the package you will find example usage code in the controllers and views

config/ion_auth.php

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,23 @@
44
| -------------------------------------------------------------------------
55
| Database Type
66
| -------------------------------------------------------------------------
7-
| If set to TRUE, IonAuth will use MongoDB as its database backend.
7+
| If set to TRUE, Ion Auth will use MongoDB as its database backend.
8+
|
9+
| If you use MongoDB there are two external dependencies that have to be
10+
| integrated with your project:
11+
| CodeIgniter MongoDB Active Record Library - http://github.com/alexbilbie/codeigniter-mongodb-library/tree/v2
12+
| CodeIgniter MongoDB Session Library - http://github.com/sepehr/ci-mongodb-session
813
*/
914
$config['use_mongodb'] = FALSE;
1015

1116
/*
1217
| -------------------------------------------------------------------------
1318
| MongoDB Collection.
1419
| -------------------------------------------------------------------------
15-
| IonAuth uses a simplified schema when using MongoDB as backend, here they are:
20+
| Setup the mongodb docs using the following command:
21+
| $ mongorestore sql/mongo
22+
|
23+
| Ion Auth uses a simplified schema when using MongoDB as backend, here they are:
1624
|
1725
| groups: {
1826
| _id: GROUP_ID,

sql/mongo/groups.bson

138 Bytes
Binary file not shown.

sql/mongo/system.indexes.bson

139 Bytes
Binary file not shown.

sql/mongo/users.bson

418 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)