Skip to content
⚡️ A dev tool for microservice developers to run local applications and/or forward others from/to Kubernetes SSH or TCP
Go Makefile Dockerfile
Branch: master
Clone or download
Latest commit 904ea13 Nov 13, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github Create FUNDING.yml Aug 1, 2019
cmd Fixed applications to be killed and relaunched correctly by file watcher Nov 11, 2019
docker-proxy Added Kubernetes remote-forward to send trafic of a pod on your machine Jul 13, 2019
internal Added support for an environment variable file on local apps Sep 21, 2019
misc Updated Monday schema Jul 19, 2019
pkg
vendor Upgrade k8s tools dependencies Sep 23, 2019
.gitignore Added vendors (to ease Homebrew installation) Jul 26, 2019
.travis.yml Fixed travis-ci github token Nov 13, 2019
Dockerfile Added a monday docker image Sep 15, 2019
LICENSE Initialization Jul 10, 2019
Makefile Fixed go binary to be found using user's env Sep 23, 2019
README.md Fixed README arm architecture download link Sep 22, 2019
example.yaml Added a new "forward_hostname" option for SSH port-forwarding Oct 4, 2019
go.mod Bump github.com/manifoldco/promptui from 0.3.1 to 0.3.2 Nov 8, 2019
go.sum Bump github.com/manifoldco/promptui from 0.3.1 to 0.3.2 Nov 8, 2019
test.env Added support for an environment variable file on local apps Sep 21, 2019

README.md

Monday: dev tool for local app and port-forwarding

TravisBuildStatus GoDoc GoReportCard

Your new microservice development environment friend. This CLI tool allows you to define a configuration to work with both local applications (Go, NodeJS, Rust or others) and forward some other applications over Kubernetes in case you don't want to run them locally.

The Monday GUI (available for macOS and Linux) application is now also available here: https://github.com/eko/monday-app

Schema

What Monday can do for you?

Define a unified way to setup applications for all your developers

Run your local applications

Hot reload your applications automatically when a change is made locally

Port-forward an application locally using a remote one on Kubernetes (targeting a pod via label) or over SSH

Forward traffic of a remote application over Kubernetes, SSH or TCP locally (see example forward types)

Auto reconnect when a port-forward connection is lost

Forward multiple times the same port locally, using an hostname

Installation

One-liner

You can download and setup Monday binary by running the following command on your terminal:

$ curl https://composieux.fr/getmonday.sh | sh

Homebrew (macOS)

$ brew install eko/homebrew-tap/monday

This will install the latest available release

Download binary

You can download the latest version of the binary built for your architecture here:

From sources

Optionally, you can download and build it from the sources. You have to retrieve the project sources by using one of the following way:

$ go get -u github.com/eko/monday
# or
$ git clone https://github.com/eko/monday.git

Install the needed vendors:

$ GO111MODULE=on go mod vendor

Then, build the binary using the available target in Makefile:

$ make build

Usage

Monday Asciinema

First, you have to initialize monday and edit your configuration file (you have a configuration example file here). Run the following command and edit the ~/monday.yaml configuration file just created for you:

⚠️ Important note: Because Monday tries to be your best dev tool and manage things for you, you have to give it some chances to help you in editing host file and manipulating network interface for IP/port mapping.

That's why I suggest to run Monday using the following alias:

alias monday='sudo -E monday'
$ monday init

Once your configuration file is ready, you can simply run Monday:

$ monday [--ui]

Note the --ui option that will allow you to enable the user interface (you can also define a MONDAY_ENABLE_UI environment variable to enable it).

Or, you can run a specific project directly by running:

$ monday run [--ui] <project name>

When you want to edit your configuration again, simply run this command to open it in your favorite editor:

$ monday edit

Environment variables

The following environment variables can be used to tweak your Monday configuration:

Environment variable Description
MONDAY_CONFIG_PATH Specify the configuration path where your YAML files can be found
MONDAY_EDITOR Specify which editor you want to use in order to edit configuration files
MONDAY_ENABLE_UI Specify that you want to use the terminal UI instead of simply logging to stdout
MONDAY_KUBE_CONFIG Specify the location of your Kubernetes config file (if not in your home directory)

Configuration

Configuration of Monday lives in one or multiple YAML files, depending on how you want to organize your files.

By default, monday init will initiates a ~/monday.yaml file. You can customize the configuration directory by setting the MONDAY_CONFIG_PATH environment variable.

Please note that you can also split this configuration in multiple files by respecting the following pattern: ~/monday.<something>.yaml, for instance:

  • ~/monday.localapps.yaml
  • ~/monday.forwards.yaml
  • ~/monday.projects.yaml

This will help you in having smaller and more readable configuration files.

To lear more about the configuration, please take a look at the Configuration Wiki page.

For an overview of what's possible with configuration file, please look at the configuration example file here.

Community

You can join the community Slack space to discuss about your issues, new features or anything else regarding Monday.

Run tests

Test suite can be run with:

$ go test -v ./...
You can’t perform that action at this time.