Last active
January 3, 2026 09:24
-
-
Save pbrilius/a1f83a445b3a294efc998f638a252254 to your computer and use it in GitHub Desktop.
se-linux LAMP full-stack!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo groupadd -g www-data | |
| sudo usermod -aG $USER www-data | |
| $VHOSTS="/var/www/vhosts" | |
| sudo mkdir -v $VHOSTS | |
| sudo chown -Rv :www-data $VHOSTS | |
| sudo chmod -Rv 2775 $VHOSTS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env sh | |
| sudo apt build-dep apache2 | |
| src | |
| wget https://dlcdn.apache.org/httpd/httpd-2.4.66.tar.gz | |
| wget https://downloads.apache.org/httpd/httpd-2.4.66.tar.gz.sha512 | |
| sha512sum --check ./httpd-*.tar.gz.sha512 | grep OK | |
| tar xvhf httpd-* | |
| cd ./httpd-* | |
| CFLAGS="-mtune=bdver4 -Og -g -pipe" ./configure --prefix=/opt/lamp --enable-rewrite --enable-exception-hook --enable-load-all-modules \ | |
| --disable-env --disable-ssl --enable-mpms-shared=all --with-mpm=event --enable-info | |
| make -j $(nproc) | |
| make install | |
| sudo usermod -aG www-data daemon |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env sh | |
| sudo apt build-dep php-cli | |
| sudo apt build-dep libapache2-mod-php | |
| src | |
| wget https://www.php.net/distributions/php-8.4.16.tar.xz | |
| sha256sum ./php-* | grep f66f8f48db34e9e29f7bfd6901178e9cf4a1b163e6e497716dfcb8f88bcfae30 | |
| tar xvfh php-* | |
| cd php-* | |
| ./configure --prefix=/opt/lamp --with-apxs2=/opt/lamp/bin/apxs --enable-opcache --without-pdo-sqlite --without-sqlite3 \ | |
| --enable-mysqlnd --with-mysqli --with-pdo-mysql | |
| make VERBOSE=1 -j $(nproc) | |
| make install |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment