Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified bin/nginx-debug-heroku-18
Binary file not shown.
Binary file modified bin/nginx-heroku-18
Binary file not shown.
20 changes: 20 additions & 0 deletions scripts/build_nginx
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,26 @@ echo "Downloading $zlib_url"
echo "Downloading $uuid4_url"
(cd nginx-${NGINX_VERSION} && curl -L $uuid4_url | tar xvz )

if [ -d "/buildpack/support/patchfiles/${NGINX_VERSION}" ]
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if [ -d "/buildpack/support/patchfiles/${NGINX_VERSION}" ]
if [ -d "/buildpack/scripts/patchfiles/${NGINX_VERSION}" ]

then
PATCHFILES=$(find /buildpack/scripts/patchfiles/${NGINX_VERSION} -name '*.patch')
else
PATCHFILES=$(find /buildpack/scripts/patchfiles/default -name '*.patch')
fi


NGX_SHUTDOWN_SIGNAL=TERM
NGX_TERMINATE_SIGNAL=QUIT

(
cd nginx-${NGINX_VERSION}
for f in $PATCHFILES
do
echo "patch: $f"
patch -p0 < $f
done
)

(
cd nginx-${NGINX_VERSION}
./configure \
Expand Down
13 changes: 13 additions & 0 deletions scripts/patchfiles/1.18.0/0001-Custom-Terminate-Signal.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
--- src/core/ngx_config.h 2020-05-23 04:21:07.000000000 +0000
+++ src/core/ngx_config.h 2020-05-23 04:15:17.000000000 +0000
@@ -56,9 +56,8 @@

#define ngx_random random

-/* TODO: #ifndef */
-#define NGX_SHUTDOWN_SIGNAL QUIT
-#define NGX_TERMINATE_SIGNAL TERM
+#define NGX_SHUTDOWN_SIGNAL TERM
+#define NGX_TERMINATE_SIGNAL QUIT
#define NGX_NOACCEPT_SIGNAL WINCH
#define NGX_RECONFIGURE_SIGNAL HUP
1 change: 1 addition & 0 deletions scripts/patchfiles/default/.gitkeep
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@