Giter Club home page Giter Club logo

ocserv-auto's Introduction

Auto Install Ocserv Server for CentOS&RedHat 7

这是 ocserv 在 CentOS 7 和 RHEL 7 的一键安装脚本,使用 epel 的二进制源,可以在最小化安装环境的 CentOS 7 和 RHEL 7 下一键部署 ocserv。

支持自动判断 firewalld 和 iptables,安装前请确保其中之一在运行。

  • 支持自动判断防火墙,请确保 Firewalld 或者 iptables 其中一个是 active 状态;
  • 可在CentOS 7系统终端执行如下命令查看状态
systemctl status firewalld
  • 默认采用用户名密码验证;
  • 默认配置文件在 /etc/ocserv/ 目录下的ocserv.conf文件;
  • 安装时会提示你输入端口、用户名、密码等信息,也可直接回车采用默认值,密码是随机生成的;
  • 安装脚本会关闭 SELINUX;
  • 尚未自带路由表,所以现在所有链接都是走VPN;如果你有需要添加的路由表可自行添加,最多支持 200 条,添加了在路由表里的 IP 才会走 VPN,;
  • 如果你有证书机构颁发的证书,可以把证书放到脚本的同目录下,确保文件名和脚本里的匹配,安装脚本会使用你的证书,客户端连接时不会提示证书错误。

=======================================

例子 CentOS 7系统

  • 先从yum安装git
yum –y install git
  • 更新git
yum update nss curl
  • 安装组件
yum install NetworkManager git epel-release
yum install net-tools
  • 拉取并执行脚本
git clone https://github.com/crh5354/ocserv-auto
cd ocserv-auto
chmod +x ocserv-auto.sh
sh ./ocserv-auto.sh
  • 最后按提示输入完成

  • 如果需要添加多个用户,每执行一次添加一个用户,username是用户账号(自行修改)

ocpasswd -c /etc/ocserv/ocpasswd username

ocserv-auto's People

Contributors

crh5354 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.