2015-06-13 17:36:15 +02:00
|
|
|
language: go
|
2018-05-29 19:40:00 +02:00
|
|
|
|
2019-09-17 21:00:42 +02:00
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- $GOPATH/pkg/mod
|
|
|
|
|
|
|
|
matrix:
|
|
|
|
fast_finish: true
|
|
|
|
include:
|
2020-02-26 01:02:29 +02:00
|
|
|
- go: 1.14.x
|
2019-09-17 21:00:42 +02:00
|
|
|
env: STABLE=true
|
|
|
|
- go: 1.x
|
|
|
|
- go: tip
|
|
|
|
allow_failures:
|
|
|
|
- go: tip
|
|
|
|
|
|
|
|
go_import_path: github.com/go-acme/lego
|
|
|
|
|
|
|
|
env:
|
|
|
|
global:
|
|
|
|
- MEMCACHED_HOSTS=localhost:11211
|
|
|
|
- GO111MODULE=on
|
2018-05-29 19:40:00 +02:00
|
|
|
|
2016-10-24 11:03:18 +02:00
|
|
|
services:
|
|
|
|
- memcached
|
2018-05-29 19:40:00 +02:00
|
|
|
|
2018-12-06 23:50:17 +02:00
|
|
|
addons:
|
|
|
|
hosts:
|
|
|
|
# for e2e tests
|
|
|
|
- acme.wtf
|
|
|
|
- lego.wtf
|
|
|
|
- acme.lego.wtf
|
|
|
|
- légô.wtf
|
|
|
|
- xn--lg-bja9b.wtf
|
|
|
|
|
2016-03-22 02:46:32 +02:00
|
|
|
before_install:
|
2018-05-29 19:40:00 +02:00
|
|
|
- '[ "${TRAVIS_PULL_REQUEST}" = "false" ] && openssl aes-256-cbc -K $encrypted_26c593b079d9_key -iv $encrypted_26c593b079d9_iv -in .gitcookies.enc -out .gitcookies -d || true'
|
2018-05-31 00:28:41 +02:00
|
|
|
|
2018-12-19 15:09:32 +02:00
|
|
|
# Install Pebble and challtestsrv
|
2019-07-30 21:19:32 +02:00
|
|
|
- GO111MODULE=off go get -u github.com/letsencrypt/pebble/...
|
2018-12-06 23:50:17 +02:00
|
|
|
|
2018-05-31 00:03:55 +02:00
|
|
|
# Install linters and misspell
|
2019-09-17 21:00:42 +02:00
|
|
|
- curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin ${GOLANGCI_LINT_VERSION}
|
2018-09-24 21:07:20 +02:00
|
|
|
- golangci-lint --version
|
2018-05-31 00:28:41 +02:00
|
|
|
|
2019-03-08 20:47:06 +02:00
|
|
|
# Hugo - documentation
|
|
|
|
- wget -O /tmp/hugo.deb https://github.com/gohugoio/hugo/releases/download/v0.54.0/hugo_0.54.0_Linux-64bit.deb
|
|
|
|
- sudo dpkg -i /tmp/hugo.deb
|
|
|
|
|
2020-03-01 22:01:41 +02:00
|
|
|
# Install Docker image multi-arch builder
|
|
|
|
- curl -sfL https://raw.githubusercontent.com/ldez/seihon/master/godownloader.sh | bash -s -- -b "${GOPATH}/bin" ${SEIHON_VERSION}
|
|
|
|
- seihon --version
|
|
|
|
|
2018-05-29 19:40:00 +02:00
|
|
|
install:
|
2019-09-17 21:00:42 +02:00
|
|
|
- go mod tidy
|
|
|
|
- git diff --exit-code go.mod
|
|
|
|
- git diff --exit-code go.sum
|
2019-07-30 21:19:32 +02:00
|
|
|
- go mod download
|
2018-05-29 19:40:00 +02:00
|
|
|
|
2019-05-06 19:09:36 +02:00
|
|
|
before_script:
|
|
|
|
- make validate-doc
|
|
|
|
|
2019-01-09 20:43:59 +02:00
|
|
|
after_success:
|
|
|
|
- make clean
|
|
|
|
|
2019-03-08 20:47:06 +02:00
|
|
|
before_deploy:
|
|
|
|
- >
|
|
|
|
if ! [ "$BEFORE_DEPLOY_RUN" ]; then
|
|
|
|
export BEFORE_DEPLOY_RUN=1;
|
2020-03-01 22:01:41 +02:00
|
|
|
make docs-build;
|
|
|
|
echo "${DOCKER_PASSWORD}" | docker login -u "${DOCKER_USERNAME}" --password-stdin;
|
2019-03-08 20:47:06 +02:00
|
|
|
fi
|
|
|
|
|
2018-05-29 19:40:00 +02:00
|
|
|
deploy:
|
2020-03-01 22:01:41 +02:00
|
|
|
- provider: pages
|
|
|
|
local_dir: docs/public
|
|
|
|
skip_cleanup: true
|
|
|
|
github_token: ${GITHUB_TOKEN}
|
|
|
|
on:
|
|
|
|
condition: $STABLE = true
|
|
|
|
|
2018-05-29 19:40:00 +02:00
|
|
|
- provider: script
|
|
|
|
skip_cleanup: true
|
|
|
|
script: curl -sL https://git.io/goreleaser | bash
|
|
|
|
on:
|
|
|
|
tags: true
|
2019-09-17 21:00:42 +02:00
|
|
|
condition: $STABLE = true
|
2018-05-29 19:40:00 +02:00
|
|
|
|
|
|
|
- provider: releases
|
|
|
|
api_key: ${GITHUB_TOKEN}
|
|
|
|
file: dist/lego_*
|
|
|
|
skip_cleanup: true
|
|
|
|
overwrite: true
|
|
|
|
file_glob: true
|
|
|
|
on:
|
|
|
|
tags: true
|
2019-09-17 21:00:42 +02:00
|
|
|
condition: $STABLE = true
|
2019-03-08 20:47:06 +02:00
|
|
|
|
2020-03-01 22:01:41 +02:00
|
|
|
- provider: script
|
2019-03-08 20:47:06 +02:00
|
|
|
skip_cleanup: true
|
2020-03-01 22:01:41 +02:00
|
|
|
script: make publish-images
|
2019-10-25 01:27:40 +02:00
|
|
|
on:
|
2020-03-01 22:01:41 +02:00
|
|
|
tags: true
|
2019-10-25 01:27:40 +02:00
|
|
|
condition: $STABLE = true
|