AKZN Notes

Archives for My Lazy and Forgetful Mind

Alpine Linux LAMP Installation Notes

Apache2

  1. .htacess : makesure AllowOverride All on directory htdocs on httpd.conf

PHP

  1. make sure all module installed
  2. Session : make sure session.save_path on php.ini is enabled

SSL Letsencrypt

  1. make sure apache-ssl module installed
    sudo apk update & sudo apk upgrade & sudo apk add apache2-ssl

  2. sudo apk add certbot-apache

  3. sudo certbot certonly

  4. make site-avalaible conf to domain which you want to add
    on alpine
    sudo nano /etc/apache2/conf.d/[yoursite.com].conf

    
    
    #ServerAdmin admin@example.com
    ServerName ib-bckp.javalatte.xyz
    #ServerAlias www.domain.com
    DocumentRoot /var/www/localhost/htdocs/ibilling/
    #ErrorLog ${APACHE_LOG_DIR}/error.log
    #CustomLog ${APACHE_LOG_DIR}/access.log combined
    
    
    
    #ServerAdmin web@master.lol
    ServerName ib-bckp.javalatte.xyz
    #ServerAlias www.example.com
    DocumentRoot /var/www/localhost/htdocs/ibilling/
    #ErrorLog ${APACHE_LOG_DIR}/error.log
    #CustomLog ${APACHE_LOG_DIR}/access.log combined
    
    SSLEngine on
    SSLCertificateFile /etc/letsencrypt/live/ib-bckp.javalatte.xyz/fullchain.pem
    SSLCertificateKeyFile /etc/letsencrypt/live/ib-bckp.javalatte.xyz/privkey.pem
    
  5. restart apache

Leave a Reply

Your email address will not be published.