forked from acmesh-official/acme.sh
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.travis.yml
38 lines (32 loc) · 1.2 KB
/
.travis.yml
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
language: shell
dist: bionic
os:
- linux
- osx
services:
- docker
matrix:
fast_finish: true
env:
global:
- SHFMT_URL=https://github.com/mvdan/sh/releases/download/v3.1.2/shfmt_v3.1.2_linux_amd64
install:
- |
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
brew update && brew install socat
export PATH="/usr/local/opt/openssl@1.1/bin:$PATH"
fi
script:
- echo "NGROK_TOKEN=$(echo "$NGROK_TOKEN" | tr '[:print:]' '*')"
- command -V openssl && openssl version
- |
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
curl -sSL "$SHFMT_URL" -o ~/shfmt && chmod +x ~/shfmt && ~/shfmt -l -w -i 2 .
git diff --exit-code && echo "shfmt OK."
shellcheck -V
shellcheck -e SC2181 **/*.sh && echo "shellcheck OK."
fi
- cd ..
- git clone --depth 1 https://github.com/acmesh-official/acmetest.git && cp -r acme.sh acmetest/ && cd acmetest
- if [ "$TRAVIS_OS_NAME" == "linux" -a "$NGROK_TOKEN" ]; then sudo TEST_LOCAL="$TEST_LOCAL" NGROK_TOKEN="$NGROK_TOKEN" ./rundocker.sh testplat ubuntu:latest ; fi
- if [ "$TRAVIS_OS_NAME" == "osx" -a "$NGROK_TOKEN" ]; then sudo TEST_LOCAL="$TEST_LOCAL" NGROK_TOKEN="$NGROK_TOKEN" ACME_OPENSSL_BIN="$ACME_OPENSSL_BIN" ./letest.sh ; fi