website/docs/articles/getting-started/index.html

169 lines
7.2 KiB
HTML

<html>
<head>
<title>Conductor: Development Stack Launcher</title>
<script src="/js/jquery-3.3.1.min.js"></script>
<script src="/js/semantic.min.js"></script>
<script src="/js/popup.min.js"></script>
<link href="/css/semantic.min.css" type="text/css" rel="stylesheet" />
<link href="/css/syntax.css" type="text/css" rel="stylesheet" />
<link href="/css/popup.min.css" type="text/css" rel="stylesheet" />
<link href="/css/styles.css" type="text/css" rel="stylesheet" />
</head>
<body>
<div class="ui menu fixed borderless">
<a class="header item" href="/">
CONDUCTOR
</a>
<a class="item" href="/articles">
DOCUMENATION
</a>
<div class="ui right secondary menu">
<a class="icon item" href="http://github.com/5Sigma/celerity"><i class="ui github icon"></i></a>
</div>
</div>
<div class="ui grid container">
<div class="two wide column"></div>
<div class="twelve wide column">
<div class="ui divider hidden"></div>
<div class="ui top attached menu borderless">
<div class="ui button icon item" id="toc-button">
<i class="icon chevron down"></i>
</div>
<div class="ui item">
<div class="ui breadcrumb small">
<a class="section" href="/"><i class="ui icon home"></i></a>
<div class="divider"> / </div>
<a class="section" href="http://conductor.5sigma.io/articles/">Articles</a>
<div class="divider"> / </div>
<div class="active section">Getting Started</div>
</div>
</div>
<div class="ui flowing popup bottom left transition hidden">
<nav id="TableOfContents">
<ul>
<li><a href="#homebrew">Homebrew</a></li>
</ul>
<ul>
<li><a href="#settting-up-a-conductoryml">Settting up a conductor.yml</a></li>
</ul>
</nav>
</div>
<div class="menu right">
<div id="reading-time" class="item">
1m
</div>
<div id="version-popup" class="ui popup inverted transition hidden">
<span style="white-space:nowrap;">
This article will take 1 minutes to
read.
</span>
</div>
<div id="version" class="item">
0.2.1
</div>
<div id="version-popup" class="ui popup inverted transition hidden">
<span style="white-space:nowrap;">
This guide was written for version 0.2.1
</span>
</div>
</div>
</div>
<article class="ui segment attached bottom">
<h1 id="installation">Installation</h1>
<p>Binaries can be downloaded for <a href="https://github.com/5Sigma/conductor/releases/latest/download/conductor-windows.zip">windows</a>, <a href="https://github.com/5Sigma/conductor/releases/latest/download/conductor-linux.tar.gz">Linux</a>,
or <a href="https://github.com/5Sigma/conductor/releases/latest/download/conductor-darwin.zip">MacOS</a></p>
<h2 id="homebrew">Homebrew</h2>
<p>On MacOS Conductor can be installed via Homebrew</p>
<div class="highlight"><pre class="chroma"><code class="language-sh" data-lang="sh">brew tap 5sigma/tap
brew install conductor
</code></pre></div><h1 id="setting-up-a-project">Setting up a project</h1>
<p>To setup a project for conductor you need to create a <code>conductor.yaml</code> somewhere in your project tree.
We will assume you have a stack that consists of 2 seperate components in a directory structure that looks
like this:</p>
<div class="highlight"><pre class="chroma"><code class="language-sh" data-lang="sh">/project
/frontend/
/backend/
/support_service/
</code></pre></div><h2 id="settting-up-a-conductoryml">Settting up a conductor.yml</h2>
<p>Conductor will search for a <code>conductor.yaml</code> anywhere in or above the current working directory. We will put the configuration
in the root <code>/project/</code> folder so it is accessible from any of the component projects.</p>
<div class="ui message">
For more information see the full <a ui button right floated" href="/articles/config">Config documentation</a>
</div>
<p>An example of a minimal configuration file could look like this:</p>
<div class="highlight"><pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="k">components</span><span class="p">:</span><span class="w">
</span><span class="w"></span>- <span class="k">name</span><span class="p">:</span><span class="w"> </span>frontend<span class="w">
</span><span class="w"> </span><span class="k">start</span><span class="p">:</span><span class="w">
</span><span class="w"></span><span class="w"> </span><span class="k">command</span><span class="p">:</span><span class="w"> </span>npm<span class="w">
</span><span class="w"> </span><span class="k">args</span><span class="p">:</span><span class="w">
</span><span class="w"></span><span class="w"> </span>- start<span class="w">
</span><span class="w"></span>- <span class="k">name</span><span class="p">:</span><span class="w"> </span>backend<span class="w">
</span><span class="w"> </span><span class="k">start</span><span class="p">:</span><span class="w">
</span><span class="w"></span><span class="w"> </span><span class="k">command</span><span class="p">:</span><span class="w"> </span>npm<span class="w">
</span><span class="w"> </span><span class="k">args</span><span class="p">:</span><span class="w">
</span><span class="w"></span><span class="w"> </span>- start<span class="w">
</span><span class="w"></span>- <span class="k">name</span><span class="p">:</span><span class="w"> </span>support<span class="w">
</span><span class="w"> </span><span class="k">start</span><span class="p">:</span><span class="w">
</span><span class="w"></span><span class="w"> </span><span class="k">command</span><span class="p">:</span><span class="w"> </span>python<span class="w">
</span><span class="w"> </span><span class="k">args</span><span class="p">:</span><span class="w">
</span><span class="w"></span><span class="w"> </span>- main.py<span class="w">
</span></code></pre></div><p>Now from the project folder or any folder below it we can launch all 3 components using:</p>
<div class="highlight"><pre class="chroma"><code class="language-sh" data-lang="sh">conductor run
</code></pre></div><p>Alternatively, we can run a single component by name:</p>
<div class="highlight"><pre class="chroma"><code class="language-sh" data-lang="sh">conductor backend
</code></pre></div>
</article>
<div class="ui segment attached compacted right aligned">
last modified Sunday, June 28, 2020
</div>
<div class="ui hidden divider"></div>
<div class="ui two column grid">
<div class="row">
<div class="column">
<div class="ui message">
<a class="ui small header" href="http://conductor.5sigma.io/articles/config/">
Configuration File Reference
</a>
<div class="text">
Conductor config file reference
</div>
</div>
</div>
</div>
</div>
</div>
<div class="two wide column"></div>
</div>
<div class="ui divider"></div>
<div class="ui center aligned segment basic">
Conductor is maintained by
<a href="http://5sigma.io">5Sigma</a>.
Source code is available at
<a href="http://github.com/5Sigma/conductor">Github</a>.
</div>
<script>
$('#toc-button').popup({
inline: true,
on: 'click'
});
$('#version').popup({
inline: true,
});
$('#reading-time').popup({
inline: true,
});
</script>
</body>
</html>