forked from mozilla/mig
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
42 lines (42 loc) · 1.29 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
39
40
41
42
language: go
go:
- '1.10'
addons:
postgresql: '9.5'
notifications:
irc:
channels:
- irc.mozilla.org#mig
services:
- docker
before_install:
- sudo apt-get update -qq
- sudo apt-get install --yes rng-tools autoconf automake gcc
- sudo rm -f /dev/random
- sudo mknod -m 0666 /dev/random c 1 9
- echo HRNGDEVICE=/dev/urandom | sudo tee /etc/default/rng-tools
- sudo /etc/init.d/rng-tools restart
script:
- make test
- bash tools/build-agent-release.sh
- docker build -t mozilla/mig .
- docker run -e MIGMODE=test mozilla/mig
- |
if [ ! -z "$TRAVIS_TAG" ]; then
# If a TRAVIS_TAG is set, this build follows a git tag --push and should trigger
# a release of a tagged container to dockerhub. Otherwise, we tag as latest.
docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS
docker tag mozilla/mig mozilla/mig:${TRAVIS_TAG}
docker tag mozilla/mig mozilla/mig:latest
docker push mozilla/mig
fi
docker logout
deploy:
provider: s3
access_key_id: AKIAIE7AXHXLPYI6OBLQ
secret_access_key:
secure: U0LhIhoa0GZGj5R2CdagKSrP9qX5HrGMYjZSNnI5LYRM/Y0XuuBRUFajit8KspCcpV/H5RAvKmGE7P8TXFy8D7doh6ZrtCqsMsfEs3VMlik0Mm6ywBybFb4yTOH6GzFAmiWD8n7B8QgxhBktJESkYj+WZ/k8Wxhw6VXeka5mvlw=
bucket: mig-agent-releases
skip_cleanup: true
region: us-west-2
local_dir: releases