rerun-trigger

command module
v0.0.0-...-a89d095 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 9, 2020 License: MIT Imports: 13 Imported by: 0

README

rerun-trigger

Simple web application which update running docker image.

Usage

Configuration

Add yaml configuration file into same directory.

Example config:

server:
  port: 8000 # Application port
spec:
  # IMPORTANT: Note that both image name and path does not include image tag.
  # Tag will be specified in each update request.
  image: nginx # Image name
  imagePath: docker.io/library/nginx # Image path to pull
  containerName: webserver
  ports:
    - containerPort: 80
      hostPort: 8080
Build and Run
go build
./rerun-trigger
Pull and Restart container

PUT /update

Pull imgage specified in config file and restart container with given name, or start if container is not running.

Note: This application does not remove the old images. It may needs to be removed.

query parameters
tag
Required
Specifies image's tag(e.g. latest, 1.17-alpine).

Example:

curl localhost:8080/update?tag=1.17 # Request run initially

curl localhost:8000 # Check if nginx is running

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL