Here are some instructions that I have used to create a working PlexAuth on a digital Ocean dropplet. http://PlexAuth.sytes.net/plexauth
- Sudo apt-get update
- Sudo apt-get install nginx #Must be version 1.5.4+ or custom built with auth_request. If you are running a version of nginx lower than 1.5.4 this link may help: https://by-example.org/install-nginx-with-http2-support-on-ubuntu-14-04-lts/
- Sudo apt-get install php5 #ignore any errors about apache2
- Sudo apt-get install php5-curl
- Sudo apt-get install php5-fpm #Depending on your setup you may need to change who nginx/php is running as. https://www.scalescale.com/tips/nginx/php5-fpm-sock-failed-13-permission-denied-error/
- Sudo apt-get install git
- cd /usr/share/nginx/html
- sudo git clone https://github.com/hjone72/PlexAuth
- sudo mv ./PlexAuth ./plexauth
- cd plexauth
- sudo cp ./nginx_example/example_2.conf /etc/nginx/conf.d/www.conf #Note that with newer versions of nginx the config might be in a different spot.
- #Edit /etc/nginx/conf.d/www.conf as needed.
- #In my example_2 I will use a free domain name “PlexAuth.sytes.net”. This will not be SSL.
- sudo mv ./plexauth/inc/sample_config.ini.php ./plexauth/inc/config.ini.php #Edit the file as needed.
- sudo mv ./plexauth/inc/nav_sample.php ./plexauth/inc/nav.php #Edit the file as needed.
- sudo mv ./plexauth/inc/footer_sample.php ./plexauth/inc/footer.php #Edit the file as needed.
- sudo mkdir ./plexauth/inc/tokens
- sudo chown www-data -R ./plexauth
- sudo chmod 775 -R ./plexauth