From ab98520118a073a6b4d8ba9d65fba014db2793d2 Mon Sep 17 00:00:00 2001 From: Ricardo Seriani Date: Thu, 5 Oct 2023 23:06:32 -0300 Subject: [PATCH 1/6] Update golang version to 1.21.2 (#1896) Signed-off-by: Ricardo Seriani --- scripts/features/golang.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/features/golang.sh b/scripts/features/golang.sh index 7d439210c..80d50bf3f 100755 --- a/scripts/features/golang.sh +++ b/scripts/features/golang.sh @@ -22,7 +22,7 @@ chown -Rf $WSL_USER_NAME:$WSL_USER_GROUP /home/$WSL_USER_NAME/.homestead-feature ARCH=$(arch) # Install Golang -golangVersion="1.20.7" +golangVersion="1.21.2" if [[ "$ARCH" == "aarch64" ]]; then wget https://dl.google.com/go/go${golangVersion}.linux-arm64.tar.gz -O golang.tar.gz else From db469da5fb089cf7dd9e1d4076ea428f2a3e367e Mon Sep 17 00:00:00 2001 From: Nicholas C <55490546+LlamaDuckGoose@users.noreply.github.com> Date: Fri, 6 Oct 2023 14:02:40 +1100 Subject: [PATCH 2/6] feat: yarn aliases matching npm (#1893) --- resources/aliases | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/resources/aliases b/resources/aliases index 1ab3ab640..cdc62a3dd 100644 --- a/resources/aliases +++ b/resources/aliases @@ -19,6 +19,12 @@ alias nrwp="npm run watch-poll" alias nrh="npm run hot" alias nrp="npm run production" +alias yrd="yarn dev" +alias yrw="yarn watch" +alias yrwp="yarn watch-poll" +alias yrh="yarn hot" +alias yrp="yarn production" + function artisan() { php artisan "$@" } From 5e3b2ef9a64b8a2010993144bba3acdd9169c399 Mon Sep 17 00:00:00 2001 From: Nicholas C <55490546+LlamaDuckGoose@users.noreply.github.com> Date: Fri, 6 Oct 2023 14:04:32 +1100 Subject: [PATCH 3/6] Ngrok default param for apache share (#1892) * feat: always include header rewrite * feat: create alias for https share --- resources/aliases | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/resources/aliases b/resources/aliases index cdc62a3dd..83f894c2c 100644 --- a/resources/aliases +++ b/resources/aliases @@ -233,7 +233,7 @@ function serve-pimcore() { function share() { if [[ "$1" ]] then - ngrok http ${@:2} $1:80 + ngrok http ${@:2} $1:80 --host-header=rewrite else echo "Error: missing required parameters." echo "Usage: " @@ -243,6 +243,19 @@ function share() { fi } +function sshare() { + if [[ "$1" ]] + then + ngrok http ${@:2} $1:443 --host-header=rewrite + else + echo "Error: missing required parameters." + echo "Usage: " + echo " sshare domain" + echo "Invocation with extra params passed directly to ngrok" + echo " sshare domain --subdomain=test1234" + fi +} + function flip() { sudo bash /vagrant/scripts/flip-webserver.sh } From 627825e9058cbdf60cef444b375d2b2768b89efe Mon Sep 17 00:00:00 2001 From: Dusan Maric Date: Fri, 6 Oct 2023 05:05:57 +0200 Subject: [PATCH 4/6] Bump MongoDB PHP driver to v1.16.2 (#1888) * mongodb.sh: bump PHP driver to 1.14.1 version * Bump MongoDB PHP driver to v1.15.0 * Install PHP8.2 MongoDB extension * mongodb.sh: fix copy'n'paste issue * Features: mongodb: bump PHP driver to v1.16.2 --------- Co-authored-by: Dusan Maric --- scripts/features/mongodb.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/features/mongodb.sh b/scripts/features/mongodb.sh index 3c0dfb44e..ebcfcfab6 100755 --- a/scripts/features/mongodb.sh +++ b/scripts/features/mongodb.sh @@ -21,7 +21,6 @@ ARCH=$(arch) touch /home/$WSL_USER_NAME/.homestead-features/mongodb chown -Rf $WSL_USER_NAME:$WSL_USER_GROUP /home/$WSL_USER_NAME/.homestead-features - if [[ "$ARCH" == "aarch64" ]]; then echo "deb [ arch=arm64 ] https://repo.mongodb.org/apt/ubuntu $(lsb_release -cs)/mongodb-org/6.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-6.0.list else @@ -41,7 +40,7 @@ sudo systemctl enable mongod sudo systemctl start mongod sudo rm -rf /tmp/mongo-php-driver /usr/src/mongo-php-driver -git clone -c advice.detachedHead=false -q -b '1.15.0' --single-branch https://github.com/mongodb/mongo-php-driver.git /tmp/mongo-php-driver +git clone -c advice.detachedHead=false -q -b '1.16.2' --single-branch https://github.com/mongodb/mongo-php-driver.git /tmp/mongo-php-driver sudo mv /tmp/mongo-php-driver /usr/src/mongo-php-driver cd /usr/src/mongo-php-driver git submodule -q update --init From cdda21768c02fe40f0f27b416176b1e7050b051d Mon Sep 17 00:00:00 2001 From: Nicholas C <55490546+LlamaDuckGoose@users.noreply.github.com> Date: Fri, 6 Oct 2023 14:08:23 +1100 Subject: [PATCH 5/6] Apache proxy site-type (#1891) * feat: add apache proxy site-type * remove .gitignore --- resources/aliases | 14 ++++ scripts/site-types/apache-proxy.sh | 104 +++++++++++++++++++++++++++++ 2 files changed, 118 insertions(+) create mode 100644 scripts/site-types/apache-proxy.sh diff --git a/resources/aliases b/resources/aliases index 83f894c2c..702b1af0d 100644 --- a/resources/aliases +++ b/resources/aliases @@ -127,6 +127,19 @@ function serve-apache() { fi } +function serve-apache-proxy() { + if [[ "$1" && "$2" ]] + then + sudo bash /vagrant/scripts/create-certificate.sh "$1" + sudo dos2unix /vagrant/scripts/site-types/apache-proxy.sh + sudo bash /vagrant/scripts/site-types/apache-proxy.sh "$1" "$2" 80 443 "${3:-8.1}" + else + echo "Error: missing required parameters." + echo "Usage: " + echo " serve-apache-proxy domain port" + fi +} + function serve-laravel() { if [[ "$1" && "$2" ]] then @@ -143,6 +156,7 @@ function serve-laravel() { function serve-proxy() { if [[ "$1" && "$2" ]] then + sudo bash /vagrant/scripts/create-certificate.sh "$1" sudo dos2unix /vagrant/scripts/site-types/proxy.sh sudo bash /vagrant/scripts/site-types/proxy.sh "$1" "$2" 80 443 "${3:-8.1}" else diff --git a/scripts/site-types/apache-proxy.sh b/scripts/site-types/apache-proxy.sh new file mode 100644 index 000000000..81fb0d97a --- /dev/null +++ b/scripts/site-types/apache-proxy.sh @@ -0,0 +1,104 @@ +#!/usr/bin/env bash + +declare -A params=$6 # Create an associative array +declare -A headers=${9} # Create an associative array +paramsTXT="" +if [ -n "$6" ]; then + for element in "${!params[@]}" + do + paramsTXT="${paramsTXT} + SetEnv ${element} \"${params[$element]}\"" + done +fi +headersTXT="" +if [ -n "${9}" ]; then + for element in "${!headers[@]}" + do + headersTXT="${headersTXT} + Header always set ${element} \"${headers[$element]}\"" + done +fi + +if [ -n "$2" ] +then + if ! [[ "$2" =~ ^[0-9]+$ ]] + then + proxyPass=" + ProxyPass / ${2}/ + ProxyPassReverse / ${2}/ + " + else proxyPass=" + ProxyPass / http://127.0.0.1:$2/ + ProxyPassReverse / http://127.0.0.1:$2/ + " + fi +else proxyPass=" +ProxyPass / http://127.0.0.1/ +ProxyPassReverse / http://127.0.0.1/ +" +fi + +export DEBIAN_FRONTEND=noninteractive + +sudo service nginx stop +sudo systemctl disable nginx +sudo systemctl enable apache2 + +sudo a2enmod proxy +sudo a2enmod proxy_http +sudo a2enmod proxy_ajp +sudo a2enmod rewrite +sudo a2enmod deflate +sudo a2enmod headers +sudo a2enmod proxy_balancer +sudo a2enmod proxy_connect +sudo a2enmod proxy_html + +block=" + ServerAdmin webmaster@localhost + ServerName $1 + ServerAlias www.$1 + + $paramsTXT + $headersTXT + + $proxyPass + + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet +" + +echo "$block" > "/etc/apache2/sites-available/$1.conf" +ln -fs "/etc/apache2/sites-available/$1.conf" "/etc/apache2/sites-enabled/$1.conf" + +blockssl=" + + ServerAdmin webmaster@localhost + ServerName $1 + ServerAlias www.$1 + + $paramsTXT + + SSLEngine on + + SSLCertificateFile /etc/ssl/certs/$1.crt + SSLCertificateKeyFile /etc/ssl/certs/$1.key + + $proxyPass + + + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet +" + +echo "$blockssl" > "/etc/apache2/sites-available/$1-ssl.conf" +ln -fs "/etc/apache2/sites-available/$1-ssl.conf" "/etc/apache2/sites-enabled/$1-ssl.conf" + +ps auxw | grep apache2 | grep -v grep > /dev/null + +service apache2 restart + +if [ $? == 0 ] +then + service apache2 reload +fi From 78d44a2f38d27f057d87c7dcff5ed2f67e07f898 Mon Sep 17 00:00:00 2001 From: Joe Ferguson Date: Thu, 5 Oct 2023 22:16:47 -0500 Subject: [PATCH 6/6] Tagging v14.5.0 --- bin/homestead | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/homestead b/bin/homestead index 1b59363a9..8448c6c53 100755 --- a/bin/homestead +++ b/bin/homestead @@ -8,7 +8,7 @@ if(is_file( __DIR__.'/../vendor/autoload.php')) { require __DIR__.'/../../../autoload.php'; } -$app = new Symfony\Component\Console\Application('Laravel Homestead', '14.4.2'); +$app = new Symfony\Component\Console\Application('Laravel Homestead', '14.5.0'); $app->add(new Laravel\Homestead\MakeCommand); $app->add(new Laravel\Homestead\WslApplyFeatures);