Giter Site home page Giter Site logo

tamsky / nomad-gitops-operator Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jonasvinther/nomad-gitops-operator

0.0 1.0 0.0 79 KB

A GitOps operator for Hashicorp Nomad

License: MIT License

Shell 0.25% Go 71.58% Makefile 5.50% HCL 22.67%

nomad-gitops-operator's Introduction

Nomoporator

Nomoporator is a GitOps operator for Hashicorp Nomad.

How to use

Setting up Nomoporator

Environment variables

It's also possible configure Nomoporator via environment variables by setting them like this:

NOMAD_ADDR - Required to overide the default of http://127.0.0.1:4646.
NOMAD_TOKEN - Required with ACLs enabled.
NOMAD_CACERT - Required with TLS enabled.
NOMAD_CLIENT_CERT - Required with TLS enabled.
NOMAD_CLIENT_KEY - Required with TLS enabled.

Bootstrapping using a git repository

Get help with ./nomoporator bootstrap git -h

Bootstrap Nomad using a git repository

Usage:
  nomoperator bootstrap git [git repo] [flags]

Flags:
      --branch string   git branch (default "main")
  -h, --help            help for git
      --path string     path relative to the repository root (default "/")
      --url string      git repository URL

Global Flags:
  -a, --address string   Address of the Nomad server

Use it like this:

./nomoperator bootstrap git --url https://github.com/jonasvinther/nomad-state.git --path /jobs --branch main

Run as Nomad job

job "nomoperator" {
  datacenters = ["dc1"]
  group "nomoperator" {
    count = 1
    task "nomoperator" {
      driver = "exec"
      config {
        command = "nomoperator"
        args    = ["bootstrap", "git", "--url", "https://github.com/jonasvinther/nomad-state.git", "--branch", "main", "--path", "/prod-env"]
      }
      artifact {
        source      = "https://github.com/jonasvinther/nomad-gitops-operator/releases/download/v0.0.1/nomad-gitops-operator_0.0.1_linux_amd64.tar.gz"
        destination = "local"
        mode        = "any"
      }
    }
  }
}

nomad-gitops-operator's People

Contributors

jonasvinther avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.