Install Centrifugo and quick start

Go is a perfect language - it gives developers an opportunity to have single binary executable file for application and cross-compile application on all target operating systems for distribution. This means that all you need to get Centrifugo - download latest release for you operating system, unpack it and you are done!

Now you can see help information for Centrifugo:

./centrifugo -h

Centrifugo server node requires configuration file with secret key. If you are new to Centrifugo then there is genconfig command which can generate minimal required configuration file for you:

+
./centrifugo genconfig

It will generate secret key for you automatically and create configuration file config.json in current directory (by default) so you can finally run Centrifugo instance:

./centrifugo --config=config.json

We will talk about configuration in detail in next sections.

You can also put or symlink centrifugo into your bin OS directory and run it from anywhere:

centrifugo --config=config.json

In production you will need to daemonize Centrifugo. We have prebuilt rpm and deb packages for most popular Linux distributions and Docker image. See more Deploy section for more info.

实际安装配置使用:

config.json:

[root@pre centrifugo]# cat /data/centrifugo/config.json
{
"secret": "y**********42",
"web": true,
"admin_password": "y***********42",
"admin_secret": "y*************42",
"namespaces": [
{
"name": "public",
"anonymous": true,
"publish": true,
"watch": true,
"presence": true,
"join_leave": true,
"history_size": 10,
"history_lifetime": 30,
"recover": true
}
]
}

启动方式:

/data/centrifugo/centrifugo -c /data/centrifugo/config.json -p 9111 --insecure_admin --log_file /data/centrifugo/centrifugo/error.log --log_level info --web &

二进制文件下载:

https://github.com/centrifugal/centrifugo/releases

Install Centrifugo and quick start的更多相关文章

  1. Darwin Streaming Server 6.0.3安装、订制、插件或模块

    How to setup Darwin Streaming Server 6.0.3 on 32 or 64 bit Linux platforms, add custom functionality ...

  2. Zend Studio / Ecliplse插件StartExplorer

    Install site.zip (quick and simple way) Locate zip file under site\target in Project Explorer, Start ...

  3. Side-by-side assembly

    Side-by-side technology is a standard for executable files in Windows 98 Second Edition, Windows 200 ...

  4. 国外大神Leo-G的 DevopsWiki

    https://raw.githubusercontent.com/Leo-G/DevopsWiki/master/README.md 总结的太好了,直接把md文件贴过来好了!慢慢学习!分享给大家,觉 ...

  5. STAR manual

    来源:STARmanual.pdf 来源:Calling variants in RNAseq PART0 准备工作 #STAR 安装前的依赖的工具 #Red Hat, CentOS, Fedora. ...

  6. 在网页中显示PDF文件及vue项目中弹出PDF

    1.<embed width="800" height="600" src="test_pdf.pdf"> </embed ...

  7. dubbo开发者指南

    开发者指南 参与 流程 任务 版本管理 源码构建 框架设计 整体设计 模块分包 依赖关系 调用链 暴露服务时序 引用服务时序 领域模型 基本原则 扩展点加载 扩展点配置 扩展点自动包装 扩展点自动装配 ...

  8. Performance Co-Pilot

    Install Performance Co-Pilot 提前安装依赖 [root@iZrj97j6t7ih9hgz1me35hZ ~]# cat install.sh yum install -y ...

  9. Red Hat Enterprise Linux 8正式发布

    现在CENTOS 8还没有发布. 了解其主要特点. https://developers.redhat.com/blog/2019/05/07/red-hat-enterprise-linux-8-n ...

随机推荐

  1. Java数据库基础(JDBC)

    JDBC(Java Data Base Connectivity):SUN公司为了简化统一对数据库的操作,定义了一套Java操作数据库的规范,称之为JDBC: 这样应用程序就不需要关注数据库底层的详细 ...

  2. MySQL改写子查询成Join

    有时用别的方式而不是子查询可以获得更高的性能 : For example: SELECT * FROM t1 WHERE id IN (SELECT id FROM t2); 改写: SELECT D ...

  3. UML图学习之二 类图

    类图(ClassDiagrams)是根据系统中的类以及各类之间的关系描述系统的静态视图.类图不仅显示系统内信息的结构,还描述系统内这些信息的行为.类图的一个重要目的是为其他图(如顺序图.交互图)定义一 ...

  4. sqllite小型数据库的使用

    1.适用场景:免安装型数据库:数据量不大,本地化管理:不依赖其他第三方类库:2.具体使用方法:添加sqllite类库引用 数据库连接定义,数据库以文件形式存储在sqllitedb/solution.d ...

  5. js_6_dom选择

    什么是dom编程? 找 找到html中的标签,赋值给一个变量 改 通过更改这个变量动态地更改html中的内容 返回的内容为列表 如何找到那些标签? id:var find = document.get ...

  6. Asp.net core 2.0.1 Razor 的使用学习笔记(一)

    环境:vs2017 版本:15.5.6 一.新建项目 1.文件>新建>项目>Visual c#>.NET Core>ASP.NET Core Web应用程序(“.NET ...

  7. hibernate的cascade

    如果项目是针对一对多的,应该在"one"方设置cascade为delete,不能在"many"方设置cascade为delete .

  8. VAssistX插件

    一.什么是VassistX? VassistX的全称是Visual Assist X,是whole tomato开发的一个非常好用的插件,可用于VC6.0及Visual Studio的各个版本(包括V ...

  9. java IO(一):File类

    */ .hljs { display: block; overflow-x: auto; padding: 0.5em; color: #333; background: #f8f8f8; } .hl ...

  10. 安卓和IOS兼容问题

    点击穿透 click延迟 scroll元素临界的bug android screen.w/h 不准 rem不准 scroll时动画失效 animate回调 最小字号限制 不同机型全屏自适应 andro ...