mirror of
https://github.com/kubernetes-sigs/node-feature-discovery.git
synced 2025-03-28 10:47:23 +00:00
travis: run e2e tests on master branch
Assumes the test cluster to be hosted in AWS. The following environment variables need to be properly configured in the CI in order to successfully run the tests: AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY AWS_REGION KUBECONFIG_AWS Also, the following are probably needed in order for the script to be be able to push the container image to the remote registry: IMAGE_REPO IMAGE_REPO_PASSWORD IMAGE_REPO_USER
This commit is contained in:
parent
ee6fd9165b
commit
a332f8bae8
1 changed files with 14 additions and 1 deletions
15
.travis.yml
15
.travis.yml
|
@ -1,15 +1,28 @@
|
|||
language: minimal
|
||||
language: go
|
||||
go:
|
||||
- "1.12"
|
||||
|
||||
env:
|
||||
global:
|
||||
# Sanitize git branch name into a valid docker tag name
|
||||
- IMAGE_TAG_NAME=$(echo -n $TRAVIS_BRANCH | tr -c "[a-zA-Z0-9._'" "_")
|
||||
- GO111MODULE=on
|
||||
|
||||
services:
|
||||
- docker
|
||||
|
||||
script:
|
||||
- make image -e
|
||||
- if [ "$TRAVIS_BRANCH" == master -a -n "$IMAGE_REPO_USER" ]; then
|
||||
set -e;
|
||||
echo "$IMAGE_REPO_PASSWORD" | docker login -u "$IMAGE_REPO_USER" --password-stdin quay.io;
|
||||
make push -e;
|
||||
curl -o $HOME/bin/aws-iam-authenticator --create-dirs https://amazon-eks.s3-us-west-2.amazonaws.com/1.10.3/2018-07-26/bin/linux/amd64/aws-iam-authenticator;
|
||||
chmod a+x $HOME/bin/aws-iam-authenticator;
|
||||
export PATH=$PATH:$HOME/bin;
|
||||
echo "$KUBECONFIG_AWS" > kubeconfig_aws;
|
||||
make e2e-test -e KUBECONFIG=`pwd`/kubeconfig_aws;
|
||||
fi
|
||||
|
||||
deploy:
|
||||
- on:
|
||||
|
|
Loading…
Add table
Reference in a new issue