Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
SilverBull committed Jan 30, 2021
1 parent 7ad53cb commit ec88186
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 43 deletions.
28 changes: 27 additions & 1 deletion index.template
Original file line number Diff line number Diff line change
@@ -1 +1,27 @@
The cake is a lie! THE CAKE IS A LIE!
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<style type="text/css" media="screen">
body {
background: #f0f0f0;
font: normal 14px sans-serif;
}
#content {
width: 400px;
margin: 50px auto;
}
h1 {
font-size: 18px;
}

</style>
<title>Web Site Coming Soon</title>
</head>
<body>
<div id="content">
<h1>Site Coming Soon</h1>
<p>This site has been successfully generated, but there's nothing here yet.</p>
</div>
</body>
</html>
8 changes: 4 additions & 4 deletions newvhost
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
#-----------------------------------------------

# User to user for permissions
tSERVERUSER="root"
tSERVERUSER="www-data"

# Location to host all virtual hosts (recommended is the home folder of the user specified above)
# Do not include a traling slash
tLOCATION="/var/www"
tLOCATION="/var/www/html"

# Safe ocation path, must be same as tLOCATION!
# Do not include a traling slash
tLOCATIONSAFE="\/var\/www"
tLOCATIONSAFE="\/var\/www/html"

# If left empty, the script will ask for MySQL root account password
tDBPW=""
Expand Down Expand Up @@ -312,7 +312,7 @@ function finished() {
echo "Database tablename: $tDBUSER"
echo "Database password: $tGENPW"
echo
echo "Please save the database password in a secure place, this is the only time you will see it!"
echo $tGENPW > /root/$tDBUSER_dbpass.txt
fi

echo
Expand Down
41 changes: 8 additions & 33 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,17 @@ Installation

1. Download the files and upload to any location on your server.
2. Edit the first section of *newvhost* after your needs.
3. Give the *installer* script execution permission with `chmod +x installer`
4. Run the installer with `sudo ./installer`
3. Give the *installer* script execution permission with `chmod +x vhinstaller`
4. Run the installer with `sudo ./vhinstaller`
5. Use the now available `sudo newvhost` command to create your first virtual host.

When finished the installation you can safely delete the files you downloaded.

Uninstallation
---------------------

1. Give the *uninstaller* script execution permission with `chmod +x uninstaller`
2. Run the uninstaller with `sudo ./uninstaller`
1. Give the *uninstaller* script execution permission with `chmod +x vhuninstaller`
2. Run the uninstaller with `sudo ./vhuninstaller`
3. Done

Configuration
Expand All @@ -35,39 +35,14 @@ Configuration
| Variable | Default value | Description |
|---------------|---------------|-------------------------------------------------------------------------------------------------|
| tSERVERUSER | root | User to user for permissions |
| tLOCATION | /var/www | Location to host all virtual hosts (recommended is the home folder of the user specified above) |
| tLOCATIONSAFE | \/var\/www | Safe ocation path, must be same as tLOCATION! |
| tLOCATION | /var/www/html | Location to host all virtual hosts (recommended is the home folder of the user specified above) |
| tLOCATIONSAFE | \/var\/www/html | Safe ocation path, must be same as tLOCATION! |
| tDBPW | null | |

Tested environment
---------------------

The script have been tested succefully on a clean machines running

- Ubuntu 14.04 LTS with Apache 2.4 and MySQL Server 5.5
- Debian 7.5 with Apache 2.4 and MySQL Server 5.5


Special thanks
---------------------

Special thanks to my friend Tzunamii for the original script and code.

By me a beer
---------------------

Like and use any of my pluings and scripts? Me too!

[By me a beer](http://darkwhispering.com/buy-me-a-beer)

Changelog
---------------------

### v1.1.0 (2015-02-18)
- Updated vhost templet for Apache 2.4+
- Added some more comments to newvhost script
- Added required section to readme
- Smaller changes to readme
Special thanks to the original creator

### v1.0.0 (2014-07-13)
- First release
[darkwhispering](https://github.com/darkwhispering/Newvhost)
File renamed without changes.
8 changes: 3 additions & 5 deletions vhost.template
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,9 @@
#

<VirtualHost *:80>

ServerName CHANGEMEVHOST

DirectoryIndex index.html index.php
DocumentRoot "CHANGEMEHOME/CHANGEMEVHOST/public"
DocumentRoot "CHANGEMEHOME/CHANGEMEVHOST/public"
ServerName CHANGEMEVHOST
ServerAlias www.CHANGEMEVHOST

# Directory settings
<Directory "CHANGEMEHOME/CHANGEMEVHOST/public">
Expand Down
File renamed without changes.

0 comments on commit ec88186

Please sign in to comment.