2019-07-31 20:57:30 +02:00
|
|
|
VHOST-MANAGER
|
|
|
|
=============
|
|
|
|
|
2021-11-29 11:50:13 +01:00
|
|
|
`vhost-manager` helps you to create apache2 vhosts.
|
2019-07-31 20:57:30 +02:00
|
|
|
|
2019-08-01 10:32:58 +02:00
|
|
|
Requirements
|
|
|
|
------------
|
2019-07-31 20:57:30 +02:00
|
|
|
|
|
|
|
* PHP
|
|
|
|
* GCC
|
2019-08-01 10:53:26 +02:00
|
|
|
* whiptail
|
2019-08-01 10:32:58 +02:00
|
|
|
* wget
|
|
|
|
* make
|
|
|
|
|
|
|
|
Installation
|
|
|
|
------------
|
2019-07-31 20:57:30 +02:00
|
|
|
|
|
|
|
```
|
2021-11-29 11:50:13 +01:00
|
|
|
$ sudo apt install gcc build-essential whiptail wget make
|
2019-08-01 10:53:26 +02:00
|
|
|
$ sudo apt install <php stuff>
|
2019-07-31 20:57:30 +02:00
|
|
|
$ git clone https://gitnet.fr/deblan/vhost-manager.git
|
|
|
|
$ cd vhost-manager
|
|
|
|
$ make
|
|
|
|
```
|
|
|
|
|
2019-08-01 10:32:58 +02:00
|
|
|
Configuration
|
|
|
|
-------------
|
|
|
|
|
|
|
|
```
|
|
|
|
$ cp etc/config.dist etc/config
|
|
|
|
$ vim etc/config
|
|
|
|
```
|
|
|
|
|
2019-07-31 20:57:30 +02:00
|
|
|
Usage
|
|
|
|
-----
|
|
|
|
|
|
|
|
```
|
2021-02-21 16:19:12 +01:00
|
|
|
USAGE:
|
|
|
|
./bin/vhost-add [options]
|
|
|
|
|
|
|
|
OPTIONS:
|
2021-11-29 11:50:13 +01:00
|
|
|
-i Enable script interactivity
|
|
|
|
The script is interactive when no argument is given
|
2021-02-21 16:19:12 +01:00
|
|
|
-d The domain name
|
|
|
|
-a Aliase(s)
|
2021-11-29 11:50:13 +01:00
|
|
|
-m value Enable "http" or "https"
|
2021-02-21 16:19:12 +01:00
|
|
|
-r Force redirection of http to https
|
|
|
|
-p value Enable PHP with the given version (eg: 8.0)
|
|
|
|
-u value Username in the system
|
|
|
|
-h Show this help
|
2019-07-31 20:57:30 +02:00
|
|
|
```
|
2019-08-01 10:32:58 +02:00
|
|
|
|
2021-02-21 16:21:51 +01:00
|
|
|
Example:
|
|
|
|
|
|
|
|
```
|
2021-11-29 11:50:13 +01:00
|
|
|
$ sudo vhost-add
|
2021-02-21 16:21:51 +01:00
|
|
|
$ sudo vhost-add -m http -m https -r -d example.com -a www.example.com -p 8.0 -u example -i
|
|
|
|
```
|
|
|
|
|
2019-08-02 10:05:25 +02:00
|
|
|
![](https://www.deblan.io/~simon/vhost-manager/vhost-manager2.gif)
|