-
Notifications
You must be signed in to change notification settings - Fork 7
/
app.yaml
50 lines (49 loc) · 2.75 KB
/
app.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
appname: "eru"
entrypoints:
elb:
cmd: "/usr/local/openresty/bin/openresty -p /elb/server -c /elb/conf/release.conf"
restart: always
dir: "/elb"
publish:
- "80"
healthcheck:
http_port: "80"
url: "/"
code: 404
log_config: "none"
privileged: true
stages:
- build
- pack
builds:
build:
base: "alpine:latest"
args:
RESTY_VERSION: "1.13.6.2"
RESTY_OPENSSL_VERSION: "1.0.2p"
RESTY_PCRE_VERSION: "8.42"
RESTY_J: "1"
RESTY_CONFIG_OPTIONS: "--with-file-aio --with-http_addition_module --with-http_auth_request_module --with-http_dav_module --with-http_flv_module --with-http_geoip_module=dynamic --with-http_gunzip_module --with-http_gzip_static_module --with-http_image_filter_module=dynamic --with-http_mp4_module --with-http_random_index_module --with-http_realip_module --with-http_secure_link_module --with-http_slice_module --with-http_ssl_module --with-http_stub_status_module --with-http_sub_module --with-http_v2_module --with-http_xslt_module=dynamic --with-ipv6 --with-mail --with-mail_ssl_module --with-md5-asm --with-pcre-jit --with-sha1-asm --with-stream --with-stream_ssl_module --with-threads "
RESTY_CONFIG_OPTIONS_MORE: "--add-module=../ngx_http_dyups_module-master"
_RESTY_CONFIG_DEPS: "--with-openssl=../openssl-${RESTY_OPENSSL_VERSION} --with-pcre=../pcre-${RESTY_PCRE_VERSION}"
commands:
- apk add --no-cache build-base curl gd-dev geoip-dev libxslt-dev linux-headers make perl-dev readline-dev zlib-dev gd geoip libgcc libxslt zlib
- curl -fSL https://github.com/yzprofile/ngx_http_dyups_module/archive/master.zip -o master.zip && unzip master.zip
- curl -fSL https://www.openssl.org/source/openssl-${RESTY_OPENSSL_VERSION}.tar.gz -o openssl-${RESTY_OPENSSL_VERSION}.tar.gz && tar xzf openssl-${RESTY_OPENSSL_VERSION}.tar.gz
- curl -fSL https://ftp.pcre.org/pub/pcre/pcre-${RESTY_PCRE_VERSION}.tar.gz -o pcre-${RESTY_PCRE_VERSION}.tar.gz && tar xzf pcre-${RESTY_PCRE_VERSION}.tar.gz
- curl -fSL https://openresty.org/download/openresty-${RESTY_VERSION}.tar.gz -o openresty-${RESTY_VERSION}.tar.gz && tar xzf openresty-${RESTY_VERSION}.tar.gz
- cd openresty-${RESTY_VERSION} &&./configure -j${RESTY_J} ${_RESTY_CONFIG_DEPS} ${RESTY_CONFIG_OPTIONS} ${RESTY_CONFIG_OPTIONS_MORE} && make -j${RESTY_J} install
cache:
/usr/local/openresty: /usr/local/openresty
pack:
labels:
ERU: 1
elb: 1
base: "alpine:latest"
# only support ssh protocol
repo: "[email protected]:projecteru2/elb.git"
version: "HEAD"
dir: /elb
commands:
- apk add --no-cache gd geoip libgcc libxslt zlib
- mkdir -p server/logs && ln -sf /dev/stdout /elb/server/logs/access.log && ln -sf /dev/stderr /elb/server/logs/error.log