LANager is a web application designed to make LAN Parties more enjoyable for attendees and organisers alike.
- Games in progress, updated every minute from Steam
- Timetable of events, optionally allowing users to sign up to events
- Achievements, created by admins, and awardable to attendees
- Attendee profiles with links to add or message on Steam
- Attendee list with their current status
- Info pages for attendees to find out about the venue, rules etc, editable by admins
- Links to other sites e.g. game stats, organiser's website
- Shouts allowing attendees and admins to broadcast short messages
- Live Dashboard showing current and next events, games in progress and shouts, for big screen display
- RESTful API with open read access and API key guarded write access to all resources
- Events dispatcher allowing for hooking in of extra operations
- Comprehensive logging of events allowing for debugging and auditing
And much more planned - check the issue tracker for future enhancements
- Web server - Apache 2.4.x recommended
- Database server - MySQL 5.5.x recommended
- Git 1.9.x
- PHP 5.5.x
- Composer 1.x
- A Steam Account
- An Internet connection
- Shell access to the server - basic web hosting alone will not work!
The installation guide is now split into several sections
- The Base OS
- Webserver Configuration
- Lanager Configuration
Advanced users will be able to deploy LANager to Windows and OS X, though LANager has not been fully tested on these OSes.
Installation on Debian 8
- Install the project's packaged dependencies:
a) For apache:
sudo apt-get install git php5-common php5-cli php5-mcrypt php5-curl php5-mysql libapache2-mod-php5 mysql-server apache2 curl
b) For nginx:sudo apt-get install git php5-common php5-cli php5-mcrypt php5-curl php5-mysql php5-fpm mysql-server nginx curl
Installation on Ubuntu Server 14.04
- Install the project's packaged dependencies:
a) For apache:
sudo apt-get install git php5-common php5-cli php5-mcrypt php5-curl php5-mysql libapache2-mod-php5 mysql-server apache2
-
Enable Apache and PHP modules:
sudo a2enmod rewrite
sudo php5enmod mcrypt curl
-
Install Composer:
sudo curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/bin/composer
-
Clone the project:
sudo git clone https://github.com/zeropingheroes/lanager.git
-
Move the project to Apache's web root directory:
sudo mv lanager /var/www/lanager
-
Install the project's dependencies:
cd /var/www/lanager
sudo composer update
-
Configure Apache to use the LANager's public directory as the web root:
-
Edit the default site configuration:
sudo nano /etc/apache2/sites-enabled/000-default.conf
-
Change the DocumentRoot line to:
DocumentRoot /var/www/lanager/public
-
Add the following lines to allow .htaccess files to set options in this directory (for pretty URLs):
<Directory /var/www/lanager/public> AllowOverride All </Directory>
-
-
Allow full read and write access on the app's storage directory:
sudo chmod -R 777 /var/www/lanager/app/storage
-
Enable PHP modules:
sudo php5enmod mcrypt curl
-
Install Composer:
sudo curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/bin/composer
-
Clone the project:
git clone https://github.com/zeropingheroes/lanager.git
-
Move the project to Nginx's web root directory:
sudo mv lanager /var/www/lanager
-
Configure Nginx to use the LANager's public directory as the web root:
-
Edit the default site configuration:
sudo nano /etc/nginx/sites-available/default
-
Change the root line to:
root /var/www/lanager/public
-
Add index.php to the default file types
index index.html index.htm index.nginx-debian.html index.php;
-
Enable larger file upload support (default is 1m)
client_max_body_size 10m;
-
Nginx doesn't support .htaccess files so we shall enable pretty URLs here instead
location / { try_files $uri $uri/ /index.php?$query_string; }
-
Enable php script processing
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000 # location ~ \.php$ { include snippets/fastcgi-php.conf; # # # With php5-cgi alone: # fastcgi_pass 127.0.0.1:9000; # # With php5-fpm: fastcgi_pass unix:/var/run/php5-fpm.sock; }
-
Lanagers document root is an apache folder, we should deny access to .htaccess files
location ~ /\.ht { deny all; }
-
-
Reload the nginx config engine
sudo systemctl reload nginx
-
Allow full read and write access on the app's storage directory:
sudo chmod -R 777 /var/www/lanager/app/storage
-
Install the project's dependencies
cd /var/www/lanager
sudo composer update
-
Create a MySQL user and database and grant the required privileges:
- Run
mysql -u root -p
- Type your MySQL root user password you chose during MySQL package installation
- Once you are at the
mysql>
prompt, run each of the following in turn:CREATE DATABASE lanager;
CREATE USER 'lanager'@'localhost' IDENTIFIED BY 'type a password here';
GRANT ALL PRIVILEGES ON lanager.* TO 'lanager'@'localhost';
FLUSH PRIVILEGES;
quit;
- Run
-
Set the database password in the database config file:
sudo nano /var/www/lanager/app/config/database.php
- Change the
password
line to your chosen password in the previous step
-
Set your Steam Web API key in the steam config file:
sudo nano /var/www/lanager/app/config/lanager/steam.php
-
Setup your app config file:
sudo nano /var/www/lanager/app/config/app.php
- Change the
timezone
value to a valid PHP timezone
-
Change the
key
value to a random 32 character string -
Run the LANager installation command:
cd /var/www/lanager
sudo php artisan lanager:install
-
Schedule the LANager Steam state import command to run at 1 minute intervals:
-
Make the script file executable
sudo chmod +x /var/www/lanager/SteamImportUserStates.sh
-
Add the script as a cron job
- Run
crontab -e
- Add the following to the end of the file:
*/1 * * * * /var/www/lanager/SteamImportUserStates.sh >> /dev/null 2>&1
- Run
-
Once you have completed the installation, you can sign in via Steam. The first user to sign in will be granted the "Super Admin" role, allowing you to assign roles to other users who sign in.
Look through the configuration files inside /var/www/lanager/app/config/lanager/
which will allow you to tailor your installation to your event.
This section will be expanded upon as features are solidified.
To update to the latest version, directory simply run the following commands:
-
Back up your config files:
sudo cp -R /var/www/lanager/app/config ~/lanager-config-backup
-
Back up your database data:
mysqldump lanager -u lanager -p --result-file=lanager.sql
-
Move to the root of the project directory:
cd /var/www/lanager
-
Reset all project files to their defaults:
sudo git reset --hard
-
Empty the database data and structure:
mysql -u root -p
DROP DATABASE lanager;
CREATE DATABASE lanager;
quit;
-
Get the latest version from the project repository:
sudo git pull origin
-
Install / update dependencies:
sudo composer update
-
Manually set your config options from the backed up files (see steps 10 and 11 from the Install guide)
-
Re-allow full read and write access on the app's storage directory:
sudo chmod -R 777 /var/www/lanager/app/storage
-
Re-run the installation command:
sudo php artisan lanager:install
Be warned that config file and database structure may have changed between versions so pay attention when copying data from backups from old versions.
- Found a bug? Got a great feature idea? Post it to the issue tracker!
- Want to contribute?
- Fork the project and add the features you want to see
- Work on new features / bug fixes in the issue tracker
- Or if you're really hardcore, request commit access
If you want to support the project in a non-technical way, we'd love it if you donated to us: