loopinstall

command
v0.9.4 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2025 License: MIT Imports: 14 Imported by: 0

README

loopinstall

A tool for installing Chainlink LOOP plugins from YAML configuration files.

Installation

To install from source:

go install github.com/smartcontractkit/chainlink-common/pkg/loop/cmd/loopinstall@latest

Or clone and install locally:

git clone https://github.com/smartcontractkit/chainlink-common.git
cd chainlink-common
go install ./pkg/loop/cmd/loopinstall

Usage

# Run `loopinstall --help` to see the options.
loopinstall [options] <plugin-config-file> [<plugin-config-file>...]

Configuration

(See plugins.example.yaml for a complete example configuration.)

Example configuration file structure:

defaults:
  # Go build flags.
  # The `-s` flag is added to strip debug information from the binary to reduce
  # the binary size for releases.
  # See: `go tool link -help`
  goflags: "-ldflags='-s'" # Default Go build flags

plugins:
  cosmos:
    - name: "default"
      moduleURI: "github.com/smartcontractkit/chainlink-cosmos"
      gitRef: "f740e9ae54e79762991bdaf8ad6b50363261c056"
      installPath: "./pkg/cosmos/cmd/chainlink-cosmos"
      libs:
        - "/go/pkg/mod/github.com/!cosm!wasm/wasmvm@v*/internal/api/libwasmvm.*.so"

The installPath is relative to the root of the downloaded module but it can also be an absolute path like: github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/cmd/chainlink-cosmos. The absolute path will be stripped to the relative path (it is supported for backwards compatibility).

The libs field is an array of strings representing directory paths, which can include glob patterns for library files that need to be included with the plugin. Docker build will use these paths to copy the libraries into the final container image.

Private Repository Access

To install plugins from private repositories:

  1. Set your GitHub token. Use the gh cli and gh auth setup-git.

  2. Optional for CI/CD only: Configure Git to use HTTPS with token authentication:

    git config --global url."https://${GITHUB_TOKEN}@github.com/".insteadOf "https://github.com/"
    
  3. Configure GOPRIVATE via environment variable:

    export GOPRIVATE=github.com/myorg/*,github.com/another-org/*
    

The GOPRIVATE environment variable supports glob patterns (e.g., github.com/myorg/*) and tells Go to bypass the public module proxy for these repositories.

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