Skip to content

schdaniel20/fbinterface

Repository files navigation

Setup config files

In storage/app -> create a new folder: "facebookConfig"

Here you must create 4 json files:

  • app.json
  • linkSource.json
  • parser.json
  • result.json

app.json

{
"id" : "facebook app id",
"secret" : "facebook app password",
"token" : "facebook app token",
"graph" : "facebook app version: v2.4"
}

linkSource.json

{
"table":"all_country_facebook",
"user":"user",
"password":"pass",
"dsn":"mysql:host=host;dbname=fb;charset=utf8"
}

parser.json

{
"table":"all_facebook_PROCESSED",
"user":"user",
"password":"pass",
"dsn":"mysql:host=host;dbname=fb;charset=utf8"
}

result.json

{
"table":"all_facebook_RESULTS",
"user":"user",
"password":"pass",
"dsn":"mysql:host=host;dbname=fb;charset=utf8"
}

Create/populate tables

In the application source directory there is a file named .env.example
Create a file named .env and paste the content of the .env.example file in it.
After that, open the .env file and change the following lines:
  • DB_HOST=localhost to mysql server ip
  • DB_DATABASE=DB_NAME to database name
  • DB_USERNAME=user to an existing user
  • DB_PASSWORD=pass to a valid passoword
For example :
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=fb
DB_USERNAME=root
DB_PASSWORD=root

When it is done, run these three commands in the application source directory:
First : php artisan migrate

In the console the following messages will appear:
Migration table created successfully.

Second: php artisan db:seed --class=CountriesTableSeeder
Third: php artisan db:seed --class=FBStatusTableSeeder
4th: php artisan db:seed --class=PermissionsTableSeeder
5th: php artisan db:seed --class=UserTypeTableSeeder


To start the facebook crawler service run the following command in the application source directory:
php artisan queue:work --queue=crawler --tries=2
To start the facebook parser service run the following command in the application source directory:
php artisan queue:work --queue=parser --tries=2

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages