dimanche 1 septembre 2019

Laravel: BroadcastException 404 NOT FOUND using Pusher?

I have been stuck on this for like 19 hours. What I was trying was to get Broadcast events working on Laravel 5.5 with pusher...

However, when i set things to pusher I am getting a 404 File not found exception:

Illuminate \ Broadcasting \ BroadcastException 404 NOT FOUND

I composer required pusher 3.0

`composer require pusher/pusher-php-server "~3.0"

.env file

APP_NAME=Laravel
APP_ENV=local
APP_KEY=base64:pwCPVeM+Ppv0SrYVLMDcnZUqKug3MlfYpTD8IqwA+Ug=
APP_DEBUG=true
APP_LOG_LEVEL=debug
APP_URL=http://localhost

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=bsproject
DB_USERNAME=root
DB_PASSWORD=

BROADCAST_DRIVER=pusher
CACHE_DRIVER=file
SESSION_DRIVER=file
QUEUE_DRIVER=sync

REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379

PUSHER_APP_ID=853485
PUSHER_APP_KEY=0261946d733c71cdd9dd
PUSHER_APP_SECRET=b98724e99d17facb3a33
PUSHER_APP_CLUSTER=AP2

ANALYTICS_VIEW_ID=

config\ broadcasting.php

<?php

return [

    'default' => env('BROADCAST_DRIVER', 'null'),

    'connections' => [

        'pusher' => [
            'driver' => 'pusher',
            'key' => env('0261946d733c71cdd9dd'),
            'secret' => env('b98724e99d17facb3a33'),
            'app_id' => env('853485'),
            'options' => [
                'cluster' => 'ap2',
                'encrypted' => false,
            ],
        ],

        'redis' => [
            'driver' => 'redis',
            'connection' => 'default',
        ],

        'log' => [
            'driver' => 'log',
        ],

        'null' => [
            'driver' => 'null',
        ],

    ],

];



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire