Skip to content

Commit ef0d425

Browse files
Deploying to gh-pages from @ dstackai/dstack@5f700f0 🚀
1 parent 50b5e17 commit ef0d425

File tree

15 files changed

+206
-238
lines changed

15 files changed

+206
-238
lines changed

docs/concepts/dev-environments/index.html

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4166,8 +4166,7 @@ <h2 id="apply-a-configuration">Apply a configuration<a class="headerlink" href="
41664166

41674167
</div>
41684168

4169-
<p><code>dstack apply</code> automatically provisions an instance, uploads the contents of the repo (incl. your local uncommitted changes),
4170-
and sets up an IDE on the instance.</p>
4169+
<p><code>dstack apply</code> automatically provisions an instance and sets up an IDE on it.</p>
41714170
<details class="info">
41724171
<summary>Windows</summary>
41734172
<p>On Windows, <code>dstack</code> works both natively and inside WSL. But, for dev environments,
@@ -4388,9 +4387,9 @@ <h3 id="environment-variables">Environment variables<a class="headerlink" href="
43884387
</table>
43894388
</details>
43904389
<h3 id="files">Files<a class="headerlink" href="#files" title="Permanent link">&para;</a></h3>
4391-
<p>By default, <code>dstack</code> automatically mounts the <a href="../repos/">repo</a> directory where you ran <code>dstack init</code> to any run configuration. </p>
4392-
<p>However, in some cases, you may not want to mount the entire directory (e.g., if it’s too large),
4393-
or you might want to mount files outside of it. In such cases, you can use the <a href="../../reference/dstack.yml/dev-environment/#files"><code>files</code></a> property.</p>
4390+
<p>If you configured a <a href="../repos/">repo</a>, <code>dstack</code> automatically mounts its content (incl. your local changes) inside the container.</p>
4391+
<p>In some cases, you don’t need to mount an entire repo and can mount only specific directories. This can be done using
4392+
<a href="../../reference/dstack.yml/task/#_files"><code>files</code></a> instead of repos.</p>
43944393
<div editor-title="examples/.dstack.yml">
43954394

43964395
<div class="highlight"><pre><span></span><code><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">dev-environment</span>
@@ -4436,7 +4435,7 @@ <h3 id="files">Files<a class="headerlink" href="#files" title="Permanent link">&
44364435

44374436
<details class="info">
44384437
<summary>.gitignore and .dstackignore</summary>
4439-
<p><code>dstack</code> automatically excludes files and folders listed in <code>.gitignore</code> and <code>.dstackignore</code>.</p>
4438+
<p>If you configured a <a href="../repos/">repo</a> or <a href="#files">files</a>, <code>dstack</code> excludes files and folders listed in <code>.gitignore</code> and <code>.dstackignore</code>.</p>
44404439
<p>Uploads are limited to 2MB. To avoid exceeding this limit, make sure to exclude unnecessary files.
44414440
You can increase the default server limit by setting the <code>DSTACK_SERVER_CODE_UPLOAD_LIMIT</code> environment variable.</p>
44424441
</details>

docs/concepts/repos/index.html

Lines changed: 18 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -1019,19 +1019,6 @@
10191019
</span>
10201020
</a>
10211021

1022-
</li>
1023-
1024-
<li class="md-nav__item">
1025-
<a href="#use-a-local-directory-instead-of-a-git-repo" class="md-nav__link">
1026-
<span class="md-ellipsis">
1027-
1028-
<span class="md-typeset">
1029-
Use a local directory instead of a Git repo
1030-
</span>
1031-
1032-
</span>
1033-
</a>
1034-
10351022
</li>
10361023

10371024
</ul>
@@ -1108,19 +1095,6 @@
11081095
</ul>
11091096
</nav>
11101097

1111-
</li>
1112-
1113-
<li class="md-nav__item">
1114-
<a href="#store-the-repo-on-a-volume" class="md-nav__link">
1115-
<span class="md-ellipsis">
1116-
1117-
<span class="md-typeset">
1118-
Store the repo on a volume
1119-
</span>
1120-
1121-
</span>
1122-
</a>
1123-
11241098
</li>
11251099

11261100
<li class="md-nav__item">
@@ -3829,19 +3803,6 @@
38293803
</span>
38303804
</a>
38313805

3832-
</li>
3833-
3834-
<li class="md-nav__item">
3835-
<a href="#use-a-local-directory-instead-of-a-git-repo" class="md-nav__link">
3836-
<span class="md-ellipsis">
3837-
3838-
<span class="md-typeset">
3839-
Use a local directory instead of a Git repo
3840-
</span>
3841-
3842-
</span>
3843-
</a>
3844-
38453806
</li>
38463807

38473808
</ul>
@@ -3918,19 +3879,6 @@
39183879
</ul>
39193880
</nav>
39203881

3921-
</li>
3922-
3923-
<li class="md-nav__item">
3924-
<a href="#store-the-repo-on-a-volume" class="md-nav__link">
3925-
<span class="md-ellipsis">
3926-
3927-
<span class="md-typeset">
3928-
Store the repo on a volume
3929-
</span>
3930-
3931-
</span>
3932-
</a>
3933-
39343882
</li>
39353883

39363884
<li class="md-nav__item">
@@ -4029,12 +3977,18 @@
40293977

40303978

40313979
<h1 id="repos">Repos<a class="headerlink" href="#repos" title="Permanent link">&para;</a></h1>
4032-
<p>Running a dev environment, task, or service with <a href="../../reference/cli/dstack/apply/"><code>dstack apply</code></a> in a directory
4033-
mounts the contents of that directory to the container’s <code>/workflow</code> directory and sets it as the container’s current working directory.
4034-
This allows accessing the directory files from within the run.</p>
3980+
<p>Repos allow mounting remote Git repos with workloads.</p>
3981+
<blockquote>
3982+
<p>Starting with 0.19.26, repos will be <a href="https://github.com/dstackai/dstack/issues/2851" target="_blank">configurable <span class="twemoji external"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="m11.93 5 2.83 2.83L5 17.59 6.42 19l9.76-9.75L19 12.07V5z"/></svg></span></a> in the run configuration. </p>
3983+
</blockquote>
3984+
<p>For now, to mount a repo with workloads, run <a href="../../reference/cli/dstack/init/"><code>dstack init</code></a> in the repo directory, and then execute <a href="../../reference/cli/dstack/apply/"><code>dstack apply</code></a> from the same directory. </p>
3985+
<p>In this case, <code>dstack</code> mounts the contents of the repo to the container’s <code>/workflow</code> directory and sets it as the container’s current working directory. Note that <code>dstack</code> also includes any local changes.</p>
3986+
<details class="info">
3987+
<summary>Files</summary>
3988+
<p>In some cases, you don’t need to mount an entire repo and can mount only specific directories. This can be done using
3989+
<a href="../../reference/dstack.yml/task/#_files"><code>files</code></a> instead of repos.</p>
3990+
</details>
40353991
<h2 id="initialize-a-repo">Initialize a repo<a class="headerlink" href="#initialize-a-repo" title="Permanent link">&para;</a></h2>
4036-
<p>To use a directory with <code>dstack apply</code>, it must first be initialized as a repo by running <a href="../../reference/cli/dstack/init/"><code>dstack init</code></a>.
4037-
The directory must be a cloned Git repo.</p>
40383992
<p><a href="../../reference/cli/dstack/init/"><code>dstack init</code></a> is not required if you pass <code>-P</code> (or <code>--repo</code>) to <a href="../../reference/cli/dstack/apply/"><code>dstack apply</code></a> (see below).</p>
40393993
<h3 id="git-credentials">Git credentials<a class="headerlink" href="#git-credentials" title="Permanent link">&para;</a></h3>
40403994
<p><a href="../../reference/cli/dstack/init/"><code>dstack init</code></a> grants the <code>dstack</code> server access by uploading the current user's default
@@ -4050,8 +4004,6 @@ <h3 id="gitignore-and-folder-size">.gitignore and folder size<a class="headerlin
40504004
<p>Uploads are limited to 2MB. Use <code>.gitignore</code> to exclude unnecessary files from being uploaded.
40514005
You can set the <code>DSTACK_SERVER_CODE_UPLOAD_LIMIT</code> environment variable to increase the default server limit.
40524006
Increasing the limit is recommended only if you <a href="../../guides/server-deployment/">configure an object storage</a>.</p>
4053-
<h3 id="use-a-local-directory-instead-of-a-git-repo">Use a local directory instead of a Git repo<a class="headerlink" href="#use-a-local-directory-instead-of-a-git-repo" title="Permanent link">&para;</a></h3>
4054-
<p>If the directory is not a cloned Git repo, use <a href="../../reference/dstack.yml/task/#_files"><code>files</code></a>.</p>
40554007
<h2 id="specify-the-repo">Specify the repo<a class="headerlink" href="#specify-the-repo" title="Permanent link">&para;</a></h2>
40564008
<p>By default, <code>dstack apply</code> uses the current directory as a repo if it is already initialized.
40574009
You can change this by explicitly specifying the repo to use for <code>dstack apply</code>.</p>
@@ -4086,11 +4038,13 @@ <h3 id="do-not-use-a-repo">Do not use a repo<a class="headerlink" href="#do-not-
40864038

40874039
</div>
40884040

4089-
<h2 id="store-the-repo-on-a-volume">Store the repo on a volume<a class="headerlink" href="#store-the-repo-on-a-volume" title="Permanent link">&para;</a></h2>
4090-
<p>You can use <a href="../volumes/">Volumes</a> to persist repo changes without pushing them to the Git remote.
4091-
Attach a volume to the repo directory (<code>/workflow</code>) or any of its subdirectories.
4092-
<code>dstack</code> will clone the repo to the volume on the first run.
4093-
On subsequent runs, <code>dstack</code> will use the repo contents from the volume instead of cloning the repo.</p>
4041+
<!-- ## Store the repo on a volume
4042+
4043+
You can use [Volumes](../concepts/volumes.md) to persist repo changes without pushing them to the Git remote.
4044+
Attach a volume to the repo directory (`/workflow`) or any of its subdirectories.
4045+
`dstack` will clone the repo to the volume on the first run.
4046+
On subsequent runs, `dstack` will use the repo contents from the volume instead of cloning the repo. -->
4047+
40944048
<h2 id="whats-next">What's next?<a class="headerlink" href="#whats-next" title="Permanent link">&para;</a></h2>
40954049
<ol>
40964050
<li>Read about <a href="../dev-environments/">dev environments</a>, <a href="../tasks/">tasks</a>, <a href="../services/">services</a></li>

docs/concepts/services/index.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4308,8 +4308,7 @@ <h2 id="apply-a-configuration">Apply a configuration<a class="headerlink" href="
43084308

43094309
</div>
43104310

4311-
<p><code>dstack apply</code> automatically provisions instances, uploads the contents of the repo (incl. your local uncommitted changes),
4312-
and runs the service.</p>
4311+
<p><code>dstack apply</code> automatically provisions instances and runs the service.</p>
43134312
<p>If a <a href="../gateways/">gateway</a> is not configured, the service’s endpoint will be accessible at
43144313
<code>&lt;dstack server URL&gt;/proxy/services/&lt;project name&gt;/&lt;run name&gt;/</code>.</p>
43154314
<div class="termy">
@@ -4782,8 +4781,9 @@ <h3 id="environment-variables">Environment variables<a class="headerlink" href="
47824781

47834782
<h3 id="files">Files<a class="headerlink" href="#files" title="Permanent link">&para;</a></h3>
47844783
<p>By default, <code>dstack</code> automatically mounts the <a href="../repos/">repo</a> directory where you ran <code>dstack init</code> to any run configuration. </p>
4785-
<p>However, in some cases, you may not want to mount the entire directory (e.g., if it’s too large),
4786-
or you might want to mount files outside of it. In such cases, you can use the <a href="../../reference/dstack.yml/dev-environment/#files"><code>files</code></a> property.</p>
4784+
<p>If you configured a <a href="../repos/">repo</a>, <code>dstack</code> automatically mounts its content (incl. your local changes) inside the container.</p>
4785+
<p>In some cases, you don’t need to mount an entire repo and can mount only specific directories. This can be done using
4786+
<a href="../../reference/dstack.yml/task/#_files"><code>files</code></a> instead of repos.</p>
47874787
<!-- TODO: Add a more relevant example -->
47884788

47894789
<div editor-title="examples/.dstack.yml">
@@ -4855,7 +4855,7 @@ <h3 id="files">Files<a class="headerlink" href="#files" title="Permanent link">&
48554855

48564856
<details class="info">
48574857
<summary>.gitignore and .dstackignore</summary>
4858-
<p><code>dstack</code> automatically excludes files and folders listed in <code>.gitignore</code> and <code>.dstackignore</code>.</p>
4858+
<p>If you configured a <a href="../repos/">repo</a> or <a href="#files">files</a>, <code>dstack</code> excludes files and folders listed in <code>.gitignore</code> and <code>.dstackignore</code>.</p>
48594859
<p>Uploads are limited to 2MB. To avoid exceeding this limit, make sure to exclude unnecessary files.
48604860
You can increase the default server limit by setting the <code>DSTACK_SERVER_CODE_UPLOAD_LIMIT</code> environment variable.</p>
48614861
</details>

docs/concepts/tasks/index.html

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4204,8 +4204,7 @@ <h2 id="apply-a-configuration">Apply a configuration<a class="headerlink" href="
42044204

42054205
</div>
42064206

4207-
<p><code>dstack apply</code> automatically provisions instances, uploads the contents of the repo (incl. your local uncommitted changes),
4208-
and runs the commands.</p>
4207+
<p><code>dstack apply</code> automatically provisions instances and runs the task.</p>
42094208
<h2 id="configuration-options">Configuration options<a class="headerlink" href="#configuration-options" title="Permanent link">&para;</a></h2>
42104209
<h3 id="ports">Ports<a class="headerlink" href="#ports" title="Permanent link">&para;</a></h3>
42114210
<p>A task can configure ports. In this case, if the task is running an application on a port, <code>dstack apply</code>
@@ -4596,9 +4595,9 @@ <h3 id="environment-variables">Environment variables<a class="headerlink" href="
45964595
</table>
45974596
</details>
45984597
<h3 id="files">Files<a class="headerlink" href="#files" title="Permanent link">&para;</a></h3>
4599-
<p>By default, <code>dstack</code> automatically mounts the <a href="../repos/">repo</a> directory where you ran <code>dstack init</code> to any run configuration. </p>
4600-
<p>However, in some cases, you may not want to mount the entire directory (e.g., if it’s too large),
4601-
or you might want to mount files outside of it. In such cases, you can use the <a href="../../reference/dstack.yml/dev-environment/#files"><code>files</code></a> property.</p>
4598+
<p>If you configured a <a href="../repos/">repo</a>, <code>dstack</code> automatically mounts its content (incl. your local changes) inside the container.</p>
4599+
<p>In some cases, you don’t need to mount an entire repo and can mount only specific directories. This can be done using
4600+
<a href="../../reference/dstack.yml/task/#_files"><code>files</code></a> instead of repos.</p>
46024601
<div editor-title="examples/.dstack.yml">
46034602

46044603
<div class="highlight"><pre><span></span><code><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">task</span>
@@ -4678,7 +4677,7 @@ <h3 id="files">Files<a class="headerlink" href="#files" title="Permanent link">&
46784677

46794678
<details class="info">
46804679
<summary>.gitignore and .dstackignore</summary>
4681-
<p><code>dstack</code> automatically excludes files and folders listed in <code>.gitignore</code> and <code>.dstackignore</code>.</p>
4680+
<p>If you configured a <a href="../repos/">repo</a> or <a href="#files">files</a>, <code>dstack</code> excludes files and folders listed in <code>.gitignore</code> and <code>.dstackignore</code>.</p>
46824681
<p>Uploads are limited to 2MB. To avoid exceeding this limit, make sure to exclude unnecessary files.
46834682
You can increase the default server limit by setting the <code>DSTACK_SERVER_CODE_UPLOAD_LIMIT</code> environment variable.</p>
46844683
</details>

0 commit comments

Comments
 (0)