mirror of
https://github.com/KevinMidboe/nginx.git
synced 2025-10-29 17:50:26 +00:00
Deploy submodule and nginx config files
This commit is contained in:
21
.drone.yml
21
.drone.yml
@@ -1,22 +1,27 @@
|
|||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
type: docker
|
type: docker
|
||||||
name: Verify
|
name: Build & deploy
|
||||||
|
|
||||||
platform:
|
platform:
|
||||||
os: linux
|
os: linux
|
||||||
arch: amd64
|
arch: amd64
|
||||||
|
|
||||||
|
clone:
|
||||||
|
disable: true
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
NGINX_VERSION: 1.24.0
|
NGINX_VERSION: 1.24.0
|
||||||
NGINX_MODULES_DIR: /opt/nginx-modules
|
NGINX_MODULES_DIR: /opt/nginx-modules
|
||||||
HEADERS_MORE_VERSION: 'v0.35'
|
HEADERS_MORE_VERSION: 'v0.35'
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: submodules
|
- name: Clone w/ submodules
|
||||||
image: alpine/git
|
image: alpine/git
|
||||||
commands:
|
commands:
|
||||||
- git submodule update --init --recursive
|
- git clone $DRONE_REPO_LINK .
|
||||||
|
- git checkout $DRONE_COMMIT
|
||||||
|
- git submodule update --init --recursive
|
||||||
|
|
||||||
- name: Verify nginx config
|
- name: Verify nginx config
|
||||||
image: ubuntu/nginx:1.24-23.10_beta
|
image: ubuntu/nginx:1.24-23.10_beta
|
||||||
@@ -26,7 +31,7 @@ steps:
|
|||||||
- name: Compile nginx
|
- name: Compile nginx
|
||||||
image: ubuntu/nginx:1.24-23.10_beta
|
image: ubuntu/nginx:1.24-23.10_beta
|
||||||
commands:
|
commands:
|
||||||
- NGINX_CONFIG_PATH=$(pwd)
|
- mkdir -p $DRONE_WORKSPACE/nginx-build
|
||||||
- apt update
|
- apt update
|
||||||
- apt install -y
|
- apt install -y
|
||||||
wget
|
wget
|
||||||
@@ -40,12 +45,16 @@ steps:
|
|||||||
- wget "http://nginx.org/download/nginx-$${NGINX_VERSION}.tar.gz"
|
- wget "http://nginx.org/download/nginx-$${NGINX_VERSION}.tar.gz"
|
||||||
- tar -xvzf nginx-$${NGINX_VERSION}.tar.gz
|
- tar -xvzf nginx-$${NGINX_VERSION}.tar.gz
|
||||||
- cd nginx-$${NGINX_VERSION}
|
- cd nginx-$${NGINX_VERSION}
|
||||||
- ./configure --prefix=/opt/nginx
|
- ./configure --prefix=$DRONE_WORKSPACE/nginx-build
|
||||||
--add-dynamic-module=../modules-available/headers-more-nginx-module
|
--add-dynamic-module=../modules-available/headers-more-nginx-module
|
||||||
--with-compat
|
--with-compat
|
||||||
- make
|
- make
|
||||||
- make install
|
- make install
|
||||||
- tree /opt/nginx
|
|
||||||
|
- name: Deploy
|
||||||
|
image: alpine/git
|
||||||
|
commands:
|
||||||
|
- tree $DRONE_WORKSPACE/nginx-build
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: signature
|
kind: signature
|
||||||
|
|||||||
Reference in New Issue
Block a user