<?php

namespace SocketWorker;

use Workerman\Worker;
use GatewayWorker\Register;

// 自动加载类
require_once __DIR__ . '/../vendor/autoload.php';
$config  = require __DIR__ . '/../../../config/im.php';

// register 必须是text协议
$register = new Register('text://0.0.0.0:'.$config['Register_port']);

// 启动
if(!defined('GLOBAL_START'))
{
    Worker::runAll();
}