Skip to content
Snippets Groups Projects

MVP build process

Merged Erick Hitter requested to merge 1-add-build into master
Compare and Show latest version
1 file
+ 17
5
Compare changes
  • Side-by-side
  • Inline
+ 17
5
#!/usr/bin/env bash
set -e
set -x
# Log when the build occurred.
date
echo ""
@@ -10,13 +13,16 @@ export OG_DIR
echo "$OG_DIR"
echo ""
# Common directories.
# Common paths.
NGINX_SRC_DIR="$OG_DIR/src/nginx"
export NGINX_SRC_DIR
mkdir -p "$NGINX_SRC_DIR"
NGINX_SRC_ARCHIVE="$OG_DIR/src/nginx-src.tar.gz"
EXPORT NGINX_SRC_ARCHIVE
export NGINX_SRC_ARCHIVE
NGINX_SRC_ARCHIVE_SIGNATURE="$OG_DIR/src/nginx-src.tar.gz.asc"
export NGINX_SRC_ARCHIVE_SIGNATURE
OPENSSL_DIR="$OG_DIR/src/openssl"
export OPENSSL_DIR
@@ -45,9 +51,15 @@ git clone -q --recursive --depth 1 https://github.com/grahamedgecombe/nginx-ct.g
# Configure nginx
echo ""
echo "DOWNLOADING NGINX RELEASE"
echo "DOWNLOADING & VERIFYING NGINX RELEASE"
cd "$OG_DIR" || exit
curl -o "$NGINX_SRC_ARCHIVE" "$NGINX_SRC"
# Disabled as nginx is signing with individuals' keys.
#curl -o "$NGINX_SRC_ARCHIVE" "$NGINX_SRC"
#curl -o "$NGINX_SRC_ARCHIVE_SIGNATURE" "$NGINX_SIGNING"
#gpg --import <(curl https://nginx.org/keys/nginx_signing.key)
#gpg --verify "$NGINX_SRC_ARCHIVE_SIGNATURE" "$NGINX_SRC_ARCHIVE"
tar -zxvf "$NGINX_SRC_ARCHIVE" -C "$NGINX_SRC_DIR" --strip 1
cd "$NGINX_SRC_DIR" || exit
./configure \
@@ -94,5 +106,5 @@ cd "$NGINX_SRC_DIR" || exit
echo ""
echo "BUILDING NGINX"
echo "Using $(nproc) jobs"
make -j$(nproc)
make -j"$(nproc)"
"$NGINX_SRC_DIR/objs/nginx -V"
Loading