You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
dotbare/buildspec.yml

36 lines
1.2 KiB
YAML

version: 0.2
env:
parameter-store:
LOGIN_PASSWORD: /dotbare/dockerpassword
LOGIN_USERNAME: /dotbare/dockerusername
phases:
install:
commands:
- echo Installing shellcheck ...
4 years ago
- apt-get update -y
4 years ago
- apt-get install shellcheck -y
pre_build:
commands:
- echo Login to dockerhub
- docker login u $LOGIN_USERNAME p $LOGIN_PASSWORD
build:
commands:
- echo Checking script compliance
- ./shellcheck.sh
4 years ago
- echo Building docker url image ...
- docker image build --build-arg MIGRATE=url -t kazhala/dotbare:testurl -f tests/Dockerfile .
- echo Running bats unittest ...
4 years ago
- docker container run -i --rm --name dotbare kazhala/dotbare:testurl
- echo Building docker bare image ...
- docker image build --build-arg MIGRATE=bare -t kazhala/dotbare:testbare -f tests/Dockerfile .
- echo Running bats unittest ...
- docker container run -i --rm --name dotbare kazhala/dotbare:testbare
- echo Building docker image ...
- docker image build -t kazhala/dotbare:latest .
post_build:
commands:
- echo Deploying docker image ...
- docker image push kazhala/dotbare:latest