-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
33 lines (29 loc) · 1006 Bytes
/
.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
language: bash
jobs:
include:
- stage: deploy
language: go
name: "Update OPA Bundle"
before_install:
- go get github.com/aktau/github-release
script:
- tar -czvf bundle.tar.gz -C bundle .
- github-release upload --replace --user $GITHUB_USER --repo $GITHUB_REPO --tag latest --name "bundle.tar.gz" --file bundle.tar.gz
- stage: deploy
name: "Deploy users image to Docker Hub"
services: docker
env:
- VERSION=latest
script:
- docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD
- docker build -t "$DOCKER_USERNAME/opa-talk-users:$VERSION" services/users
- docker push "$DOCKER_USERNAME/opa-talk-users:$VERSION"
- stage: deploy
name: "Deploy likes image to Docker Hub"
services: docker
env:
- VERSION=latest
script:
- docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD
- docker build -t "$DOCKER_USERNAME/opa-talk-likes:$VERSION" services/likes
- docker push "$DOCKER_USERNAME/opa-talk-likes:$VERSION"