fix realtimePort
This commit is contained in:
parent
423dfc6280
commit
f0ee26cd86
@ -6,6 +6,7 @@ use Illuminate\Support\Facades\Http;
|
|||||||
use Illuminate\Support\ServiceProvider;
|
use Illuminate\Support\ServiceProvider;
|
||||||
use Laravel\Sanctum\Sanctum;
|
use Laravel\Sanctum\Sanctum;
|
||||||
use App\Models\PersonalAccessToken;
|
use App\Models\PersonalAccessToken;
|
||||||
|
use Illuminate\Support\Facades\Config;
|
||||||
|
|
||||||
class AppServiceProvider extends ServiceProvider
|
class AppServiceProvider extends ServiceProvider
|
||||||
{
|
{
|
||||||
@ -16,7 +17,6 @@ class AppServiceProvider extends ServiceProvider
|
|||||||
public function boot(): void
|
public function boot(): void
|
||||||
{
|
{
|
||||||
Sanctum::usePersonalAccessTokenModel(PersonalAccessToken::class);
|
Sanctum::usePersonalAccessTokenModel(PersonalAccessToken::class);
|
||||||
|
|
||||||
Http::macro('github', function (string $api_url, string|null $github_access_token = null) {
|
Http::macro('github', function (string $api_url, string|null $github_access_token = null) {
|
||||||
if ($github_access_token) {
|
if ($github_access_token) {
|
||||||
return Http::withHeaders([
|
return Http::withHeaders([
|
||||||
@ -30,5 +30,6 @@ class AppServiceProvider extends ServiceProvider
|
|||||||
])->baseUrl($api_url);
|
])->baseUrl($api_url);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
view()->share('realtimePort', \App\Models\InstanceSettings::realtimePort() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -52,8 +52,8 @@
|
|||||||
cluster: "{{ env('PUSHER_HOST') }}" || window.location.hostname,
|
cluster: "{{ env('PUSHER_HOST') }}" || window.location.hostname,
|
||||||
key: "{{ env('PUSHER_APP_KEY') }}" || 'coolify',
|
key: "{{ env('PUSHER_APP_KEY') }}" || 'coolify',
|
||||||
wsHost: "{{ env('PUSHER_HOST') }}" || window.location.hostname,
|
wsHost: "{{ env('PUSHER_HOST') }}" || window.location.hostname,
|
||||||
wsPort: "{{ App\Models\InstanceSettings::realtimePort() }}",
|
wsPort: "{{ $realtimePort }}",
|
||||||
wssPort: "{{ App\Models\InstanceSettings::realtimePort() }}",
|
wssPort: "{{ $realtimePort }}",
|
||||||
forceTLS: false,
|
forceTLS: false,
|
||||||
encrypted: true,
|
encrypted: true,
|
||||||
enableStats: false,
|
enableStats: false,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user