testing dockerhub

This commit is contained in:
Jonathan Shook 2020-05-21 12:00:09 -05:00 committed by GitHub
parent 7020bcf20d
commit 0877afc86b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

26
.github/workflows/dockerpub.yml vendored Normal file
View File

@ -0,0 +1,26 @@
name: dockerpub
on:
push:
tags: nosqlbench-**
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Login to DockerHub Registry
run: echo ${{ secrets.DOCKERHUB_PASSWORD }} | docker login -u ${{ secrets.DOCKERHUB_USERNAME }} --password-stdin
- name: Get the version
id: vars
run: echo ::set-output name=tag::$(echo ${GITHUB_REF:10})
- name: Build the tagged Docker image
run: docker build ./nb/ --file Dockerfile --tag nosqlbench/nosqlbench:${{steps.vars.outputs.tag}}
- name: Push the tagged Docker image
run: docker push nosqlbench/nosqlbench:${{steps.vars.outputs.tag}}
- name: Build the latest Docker image
run: docker build ./nb/ --file Dockerfile --tag nosqlbench/nosqlbench:latest
- name: Push the latest Docker image
run: docker push nosqlbench/nosqlbench:latest