Yiiboilerplate User Extension


I’ve started to use the Yiiboilerplate. I think this is great directory structure, but I have a very big problem…

I can’t create the user table in my database and the

./runpostdeploy environmentType migrations

command always give me exceptions.

At firstly I don’t find any step by step guide, how I can setting the user table and I still don’t find any good article by the google.

At firstly I configurated the db connections. It is good. Then I executed this command in terminal(ubuntu):

./runpostdeploy environmentType migrations

The result was a lot of exceptions… the first was: “Don’t find the tbl_migration table”. Okay, so I created this table in my database.

After this I got another exception: "‘CDbException’ with message ‘CDbCommand failed to execute the SQL statement: SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘version’ in ‘field list’’ ". And I don’t know, what kind of table shema I have to use on tbl_migration. I don’t find any information about this.

I just would like to run /console/migration/m120805_131754_user_table_migration.php file, but I don’t have any ideas how I can run it…

Somebody Can give me a step by step guide? :)

Any luck, have you figure out how to do it step by step that may help me.

I want to setup locally then upload it to prod server. (I prefer this way.)

And was files should be remove when the locally project is ready to upload.(security concerns)

YII Boilerplate Install Instructions

Copy yiiboilerplate folder and rename

Map admin.domainname.com (or similar) to backend > www

Map domainname.com (or similar) to frontend > www (if required)

Create database for app

Create database for test with suffix _test (if required)

Add db details to common > config > params-local.php

  • OR common > config > environments > [ either of the files here ( params-private.php or params-prod.php depending on what you need or copy one of them as a template to create one for the environment you’re setting up like params-staging.php ]

Remove comments from db connections in console > config > main.php

Remove comments from db connections and gii in backend > config > main.php

Remove comments from db connections in frontend > config > main.php (if required)

$ ./runpostdeploy local no-migrate

$ ./yiic migrate

go to admin.domainname.com and bobs your uncle.