Skip to content

killgallic/docker-action

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Publish docker action

This action publish docker image to your registry

Inputs

username

Required username for container registry authentication .

password

Required password for container registry authentication.

repository

Required Github repository name

docker_repository

Required Container registry repository name

registry

Required Hostname of the container repository

pat_string

Required Github Personal Access Token string in https://[USERNAME]:[PERSONAL_ACCESS_TOKEN]@github.com format

tag

Image tag. If you don't want to set, it is set to latest

Outputs

image

Tagged image name

Example usage

    uses: spi-dot-dev/docker-action@master 
    with: # These are injested as arguments in docker-action/entrypoint.sh
        username: ${{ secrets.DOCKER_USERNAME }} 
        password: ${{ secrets.DOCKER_PASSWORD }}
        repository: ${{ github.repository }} 
        docker_repository: 'dockerhub-username/repo-name'
        registry: registry.hub.docker.com 
        pat_string: ${{ secrets.PAT_STRING }}
        tag: ${{ github.ref }} # or specify yourself!
        # To use github's container repository replace
        # registry: docker.pkg.github.com
        # repository: user/test-repo/test-app

A full example can be found in the /workflows/example.yml file

About

GitHub Actions for build and publish Docker Image

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 73.9%
  • Dockerfile 26.1%