@dagger.io/dagger 0.6.2 → 0.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/api/client.gen.js
CHANGED
|
@@ -54,7 +54,7 @@ export var CacheSharingMode;
|
|
|
54
54
|
CacheSharingMode[CacheSharingMode["Shared"] = 2] = "Shared";
|
|
55
55
|
})(CacheSharingMode || (CacheSharingMode = {}));
|
|
56
56
|
/**
|
|
57
|
-
* Compression algorithm to use for image layers
|
|
57
|
+
* Compression algorithm to use for image layers.
|
|
58
58
|
*/
|
|
59
59
|
export var ImageLayerCompression;
|
|
60
60
|
(function (ImageLayerCompression) {
|
|
@@ -63,6 +63,14 @@ export var ImageLayerCompression;
|
|
|
63
63
|
ImageLayerCompression[ImageLayerCompression["Uncompressed"] = 2] = "Uncompressed";
|
|
64
64
|
ImageLayerCompression[ImageLayerCompression["Zstd"] = 3] = "Zstd";
|
|
65
65
|
})(ImageLayerCompression || (ImageLayerCompression = {}));
|
|
66
|
+
/**
|
|
67
|
+
* Mediatypes to use in published or exported image metadata.
|
|
68
|
+
*/
|
|
69
|
+
export var ImageMediaTypes;
|
|
70
|
+
(function (ImageMediaTypes) {
|
|
71
|
+
ImageMediaTypes[ImageMediaTypes["Dockermediatypes"] = 0] = "Dockermediatypes";
|
|
72
|
+
ImageMediaTypes[ImageMediaTypes["Ocimediatypes"] = 1] = "Ocimediatypes";
|
|
73
|
+
})(ImageMediaTypes || (ImageMediaTypes = {}));
|
|
66
74
|
/**
|
|
67
75
|
* Transport layer network protocol associated to a port.
|
|
68
76
|
*/
|
|
@@ -92,30 +100,6 @@ export class CacheVolume extends BaseClient {
|
|
|
92
100
|
return response;
|
|
93
101
|
});
|
|
94
102
|
}
|
|
95
|
-
/**
|
|
96
|
-
* Chain objects together
|
|
97
|
-
* @example
|
|
98
|
-
* ```ts
|
|
99
|
-
* function AddAFewMounts(c) {
|
|
100
|
-
* return c
|
|
101
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
102
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
103
|
-
* }
|
|
104
|
-
*
|
|
105
|
-
* connect(async (client) => {
|
|
106
|
-
* const tree = await client
|
|
107
|
-
* .container()
|
|
108
|
-
* .from("alpine")
|
|
109
|
-
* .withWorkdir("/foo")
|
|
110
|
-
* .with(AddAFewMounts)
|
|
111
|
-
* .withExec(["ls", "-lh"])
|
|
112
|
-
* .stdout()
|
|
113
|
-
* })
|
|
114
|
-
*```
|
|
115
|
-
*/
|
|
116
|
-
with(arg) {
|
|
117
|
-
return arg(this);
|
|
118
|
-
}
|
|
119
103
|
}
|
|
120
104
|
/**
|
|
121
105
|
* An OCI-compatible container, also known as a docker container.
|
|
@@ -274,6 +258,7 @@ export class Container extends BaseClient {
|
|
|
274
258
|
* Exit code of the last executed command. Zero means success.
|
|
275
259
|
*
|
|
276
260
|
* Will execute default command if none is set, or error if there's no default.
|
|
261
|
+
* @deprecated Use sync instead.
|
|
277
262
|
*/
|
|
278
263
|
exitCode() {
|
|
279
264
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -300,6 +285,9 @@ export class Container extends BaseClient {
|
|
|
300
285
|
* cache, that will be used (this can result in a mix of compression algorithms for
|
|
301
286
|
* different layers). If this is unset and a layer has no compressed blob in the
|
|
302
287
|
* engine's cache, then it will be compressed using Gzip.
|
|
288
|
+
* @param opts.mediaTypes Use the specified media types for the exported image's layers. Defaults to OCI, which
|
|
289
|
+
* is largely compatible with most recent container runtimes, but Docker may be needed
|
|
290
|
+
* for older runtimes without OCI support.
|
|
303
291
|
*/
|
|
304
292
|
export(path, opts) {
|
|
305
293
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -543,6 +531,9 @@ export class Container extends BaseClient {
|
|
|
543
531
|
* cache, that will be used (this can result in a mix of compression algorithms for
|
|
544
532
|
* different layers). If this is unset and a layer has no compressed blob in the
|
|
545
533
|
* engine's cache, then it will be compressed using Gzip.
|
|
534
|
+
* @param opts.mediaTypes Use the specified media types for the published image's layers. Defaults to OCI, which
|
|
535
|
+
* is largely compatible with most recent registries, but Docker may be needed for older
|
|
536
|
+
* registries without OCI support.
|
|
546
537
|
*/
|
|
547
538
|
publish(address, opts) {
|
|
548
539
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -811,6 +802,22 @@ export class Container extends BaseClient {
|
|
|
811
802
|
sessionToken: this.sessionToken,
|
|
812
803
|
});
|
|
813
804
|
}
|
|
805
|
+
/**
|
|
806
|
+
* Indicate that subsequent operations should be featured more prominently in
|
|
807
|
+
* the UI.
|
|
808
|
+
*/
|
|
809
|
+
withFocus() {
|
|
810
|
+
return new Container({
|
|
811
|
+
queryTree: [
|
|
812
|
+
...this._queryTree,
|
|
813
|
+
{
|
|
814
|
+
operation: "withFocus",
|
|
815
|
+
},
|
|
816
|
+
],
|
|
817
|
+
host: this.clientHost,
|
|
818
|
+
sessionToken: this.sessionToken,
|
|
819
|
+
});
|
|
820
|
+
}
|
|
814
821
|
/**
|
|
815
822
|
* Retrieves this container plus the given label.
|
|
816
823
|
* @param name The name of the label (e.g., "org.opencontainers.artifact.created").
|
|
@@ -1145,6 +1152,24 @@ export class Container extends BaseClient {
|
|
|
1145
1152
|
sessionToken: this.sessionToken,
|
|
1146
1153
|
});
|
|
1147
1154
|
}
|
|
1155
|
+
/**
|
|
1156
|
+
* Indicate that subsequent operations should not be featured more prominently
|
|
1157
|
+
* in the UI.
|
|
1158
|
+
*
|
|
1159
|
+
* This is the initial state of all containers.
|
|
1160
|
+
*/
|
|
1161
|
+
withoutFocus() {
|
|
1162
|
+
return new Container({
|
|
1163
|
+
queryTree: [
|
|
1164
|
+
...this._queryTree,
|
|
1165
|
+
{
|
|
1166
|
+
operation: "withoutFocus",
|
|
1167
|
+
},
|
|
1168
|
+
],
|
|
1169
|
+
host: this.clientHost,
|
|
1170
|
+
sessionToken: this.sessionToken,
|
|
1171
|
+
});
|
|
1172
|
+
}
|
|
1148
1173
|
/**
|
|
1149
1174
|
* Retrieves this container minus the given environment label.
|
|
1150
1175
|
* @param name The name of the label to remove (e.g., "org.opencontainers.artifact.created").
|
|
@@ -1229,25 +1254,9 @@ export class Container extends BaseClient {
|
|
|
1229
1254
|
});
|
|
1230
1255
|
}
|
|
1231
1256
|
/**
|
|
1232
|
-
*
|
|
1233
|
-
* @example
|
|
1234
|
-
* ```ts
|
|
1235
|
-
* function AddAFewMounts(c) {
|
|
1236
|
-
* return c
|
|
1237
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
1238
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
1239
|
-
* }
|
|
1257
|
+
* Call the provided function with current Container.
|
|
1240
1258
|
*
|
|
1241
|
-
*
|
|
1242
|
-
* const tree = await client
|
|
1243
|
-
* .container()
|
|
1244
|
-
* .from("alpine")
|
|
1245
|
-
* .withWorkdir("/foo")
|
|
1246
|
-
* .with(AddAFewMounts)
|
|
1247
|
-
* .withExec(["ls", "-lh"])
|
|
1248
|
-
* .stdout()
|
|
1249
|
-
* })
|
|
1250
|
-
*```
|
|
1259
|
+
* This is useful for reusability and readability by not breaking the calling chain.
|
|
1251
1260
|
*/
|
|
1252
1261
|
with(arg) {
|
|
1253
1262
|
return arg(this);
|
|
@@ -1398,6 +1407,20 @@ export class Directory extends BaseClient {
|
|
|
1398
1407
|
sessionToken: this.sessionToken,
|
|
1399
1408
|
});
|
|
1400
1409
|
}
|
|
1410
|
+
/**
|
|
1411
|
+
* Force evaluation in the engine.
|
|
1412
|
+
*/
|
|
1413
|
+
sync() {
|
|
1414
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1415
|
+
yield computeQuery([
|
|
1416
|
+
...this._queryTree,
|
|
1417
|
+
{
|
|
1418
|
+
operation: "sync",
|
|
1419
|
+
},
|
|
1420
|
+
], this.client);
|
|
1421
|
+
return this;
|
|
1422
|
+
});
|
|
1423
|
+
}
|
|
1401
1424
|
/**
|
|
1402
1425
|
* Retrieves this directory plus a directory written at the given path.
|
|
1403
1426
|
* @param path Location of the written directory (e.g., "/src/").
|
|
@@ -1534,25 +1557,9 @@ export class Directory extends BaseClient {
|
|
|
1534
1557
|
});
|
|
1535
1558
|
}
|
|
1536
1559
|
/**
|
|
1537
|
-
*
|
|
1538
|
-
* @example
|
|
1539
|
-
* ```ts
|
|
1540
|
-
* function AddAFewMounts(c) {
|
|
1541
|
-
* return c
|
|
1542
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
1543
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
1544
|
-
* }
|
|
1560
|
+
* Call the provided function with current Directory.
|
|
1545
1561
|
*
|
|
1546
|
-
*
|
|
1547
|
-
* const tree = await client
|
|
1548
|
-
* .container()
|
|
1549
|
-
* .from("alpine")
|
|
1550
|
-
* .withWorkdir("/foo")
|
|
1551
|
-
* .with(AddAFewMounts)
|
|
1552
|
-
* .withExec(["ls", "-lh"])
|
|
1553
|
-
* .stdout()
|
|
1554
|
-
* })
|
|
1555
|
-
*```
|
|
1562
|
+
* This is useful for reusability and readability by not breaking the calling chain.
|
|
1556
1563
|
*/
|
|
1557
1564
|
with(arg) {
|
|
1558
1565
|
return arg(this);
|
|
@@ -1590,30 +1597,6 @@ export class EnvVariable extends BaseClient {
|
|
|
1590
1597
|
return response;
|
|
1591
1598
|
});
|
|
1592
1599
|
}
|
|
1593
|
-
/**
|
|
1594
|
-
* Chain objects together
|
|
1595
|
-
* @example
|
|
1596
|
-
* ```ts
|
|
1597
|
-
* function AddAFewMounts(c) {
|
|
1598
|
-
* return c
|
|
1599
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
1600
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
1601
|
-
* }
|
|
1602
|
-
*
|
|
1603
|
-
* connect(async (client) => {
|
|
1604
|
-
* const tree = await client
|
|
1605
|
-
* .container()
|
|
1606
|
-
* .from("alpine")
|
|
1607
|
-
* .withWorkdir("/foo")
|
|
1608
|
-
* .with(AddAFewMounts)
|
|
1609
|
-
* .withExec(["ls", "-lh"])
|
|
1610
|
-
* .stdout()
|
|
1611
|
-
* })
|
|
1612
|
-
*```
|
|
1613
|
-
*/
|
|
1614
|
-
with(arg) {
|
|
1615
|
-
return arg(this);
|
|
1616
|
-
}
|
|
1617
1600
|
}
|
|
1618
1601
|
/**
|
|
1619
1602
|
* A file.
|
|
@@ -1695,6 +1678,20 @@ export class File extends BaseClient {
|
|
|
1695
1678
|
return response;
|
|
1696
1679
|
});
|
|
1697
1680
|
}
|
|
1681
|
+
/**
|
|
1682
|
+
* Force evaluation in the engine.
|
|
1683
|
+
*/
|
|
1684
|
+
sync() {
|
|
1685
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1686
|
+
yield computeQuery([
|
|
1687
|
+
...this._queryTree,
|
|
1688
|
+
{
|
|
1689
|
+
operation: "sync",
|
|
1690
|
+
},
|
|
1691
|
+
], this.client);
|
|
1692
|
+
return this;
|
|
1693
|
+
});
|
|
1694
|
+
}
|
|
1698
1695
|
/**
|
|
1699
1696
|
* Retrieves this file with its created/modified timestamps set to the given time.
|
|
1700
1697
|
* @param timestamp Timestamp to set dir/files in.
|
|
@@ -1715,25 +1712,9 @@ export class File extends BaseClient {
|
|
|
1715
1712
|
});
|
|
1716
1713
|
}
|
|
1717
1714
|
/**
|
|
1718
|
-
*
|
|
1719
|
-
* @example
|
|
1720
|
-
* ```ts
|
|
1721
|
-
* function AddAFewMounts(c) {
|
|
1722
|
-
* return c
|
|
1723
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
1724
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
1725
|
-
* }
|
|
1715
|
+
* Call the provided function with current File.
|
|
1726
1716
|
*
|
|
1727
|
-
*
|
|
1728
|
-
* const tree = await client
|
|
1729
|
-
* .container()
|
|
1730
|
-
* .from("alpine")
|
|
1731
|
-
* .withWorkdir("/foo")
|
|
1732
|
-
* .with(AddAFewMounts)
|
|
1733
|
-
* .withExec(["ls", "-lh"])
|
|
1734
|
-
* .stdout()
|
|
1735
|
-
* })
|
|
1736
|
-
*```
|
|
1717
|
+
* This is useful for reusability and readability by not breaking the calling chain.
|
|
1737
1718
|
*/
|
|
1738
1719
|
with(arg) {
|
|
1739
1720
|
return arg(this);
|
|
@@ -1743,20 +1724,6 @@ export class File extends BaseClient {
|
|
|
1743
1724
|
* A git ref (tag, branch or commit).
|
|
1744
1725
|
*/
|
|
1745
1726
|
export class GitRef extends BaseClient {
|
|
1746
|
-
/**
|
|
1747
|
-
* The digest of the current value of this ref.
|
|
1748
|
-
*/
|
|
1749
|
-
digest() {
|
|
1750
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1751
|
-
const response = yield computeQuery([
|
|
1752
|
-
...this._queryTree,
|
|
1753
|
-
{
|
|
1754
|
-
operation: "digest",
|
|
1755
|
-
},
|
|
1756
|
-
], this.client);
|
|
1757
|
-
return response;
|
|
1758
|
-
});
|
|
1759
|
-
}
|
|
1760
1727
|
/**
|
|
1761
1728
|
* The filesystem tree at this ref.
|
|
1762
1729
|
*/
|
|
@@ -1773,30 +1740,6 @@ export class GitRef extends BaseClient {
|
|
|
1773
1740
|
sessionToken: this.sessionToken,
|
|
1774
1741
|
});
|
|
1775
1742
|
}
|
|
1776
|
-
/**
|
|
1777
|
-
* Chain objects together
|
|
1778
|
-
* @example
|
|
1779
|
-
* ```ts
|
|
1780
|
-
* function AddAFewMounts(c) {
|
|
1781
|
-
* return c
|
|
1782
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
1783
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
1784
|
-
* }
|
|
1785
|
-
*
|
|
1786
|
-
* connect(async (client) => {
|
|
1787
|
-
* const tree = await client
|
|
1788
|
-
* .container()
|
|
1789
|
-
* .from("alpine")
|
|
1790
|
-
* .withWorkdir("/foo")
|
|
1791
|
-
* .with(AddAFewMounts)
|
|
1792
|
-
* .withExec(["ls", "-lh"])
|
|
1793
|
-
* .stdout()
|
|
1794
|
-
* })
|
|
1795
|
-
*```
|
|
1796
|
-
*/
|
|
1797
|
-
with(arg) {
|
|
1798
|
-
return arg(this);
|
|
1799
|
-
}
|
|
1800
1743
|
}
|
|
1801
1744
|
/**
|
|
1802
1745
|
* A git repository.
|
|
@@ -1819,20 +1762,6 @@ export class GitRepository extends BaseClient {
|
|
|
1819
1762
|
sessionToken: this.sessionToken,
|
|
1820
1763
|
});
|
|
1821
1764
|
}
|
|
1822
|
-
/**
|
|
1823
|
-
* Lists of branches on the repository.
|
|
1824
|
-
*/
|
|
1825
|
-
branches() {
|
|
1826
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1827
|
-
const response = yield computeQuery([
|
|
1828
|
-
...this._queryTree,
|
|
1829
|
-
{
|
|
1830
|
-
operation: "branches",
|
|
1831
|
-
},
|
|
1832
|
-
], this.client);
|
|
1833
|
-
return response;
|
|
1834
|
-
});
|
|
1835
|
-
}
|
|
1836
1765
|
/**
|
|
1837
1766
|
* Returns details on one commit.
|
|
1838
1767
|
* @param id Identifier of the commit (e.g., "b6315d8f2810962c601af73f86831f6866ea798b").
|
|
@@ -1867,44 +1796,6 @@ export class GitRepository extends BaseClient {
|
|
|
1867
1796
|
sessionToken: this.sessionToken,
|
|
1868
1797
|
});
|
|
1869
1798
|
}
|
|
1870
|
-
/**
|
|
1871
|
-
* Lists of tags on the repository.
|
|
1872
|
-
*/
|
|
1873
|
-
tags() {
|
|
1874
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1875
|
-
const response = yield computeQuery([
|
|
1876
|
-
...this._queryTree,
|
|
1877
|
-
{
|
|
1878
|
-
operation: "tags",
|
|
1879
|
-
},
|
|
1880
|
-
], this.client);
|
|
1881
|
-
return response;
|
|
1882
|
-
});
|
|
1883
|
-
}
|
|
1884
|
-
/**
|
|
1885
|
-
* Chain objects together
|
|
1886
|
-
* @example
|
|
1887
|
-
* ```ts
|
|
1888
|
-
* function AddAFewMounts(c) {
|
|
1889
|
-
* return c
|
|
1890
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
1891
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
1892
|
-
* }
|
|
1893
|
-
*
|
|
1894
|
-
* connect(async (client) => {
|
|
1895
|
-
* const tree = await client
|
|
1896
|
-
* .container()
|
|
1897
|
-
* .from("alpine")
|
|
1898
|
-
* .withWorkdir("/foo")
|
|
1899
|
-
* .with(AddAFewMounts)
|
|
1900
|
-
* .withExec(["ls", "-lh"])
|
|
1901
|
-
* .stdout()
|
|
1902
|
-
* })
|
|
1903
|
-
*```
|
|
1904
|
-
*/
|
|
1905
|
-
with(arg) {
|
|
1906
|
-
return arg(this);
|
|
1907
|
-
}
|
|
1908
1799
|
}
|
|
1909
1800
|
/**
|
|
1910
1801
|
* Information about the host execution environment.
|
|
@@ -1999,30 +1890,6 @@ export class Host extends BaseClient {
|
|
|
1999
1890
|
sessionToken: this.sessionToken,
|
|
2000
1891
|
});
|
|
2001
1892
|
}
|
|
2002
|
-
/**
|
|
2003
|
-
* Chain objects together
|
|
2004
|
-
* @example
|
|
2005
|
-
* ```ts
|
|
2006
|
-
* function AddAFewMounts(c) {
|
|
2007
|
-
* return c
|
|
2008
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2009
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2010
|
-
* }
|
|
2011
|
-
*
|
|
2012
|
-
* connect(async (client) => {
|
|
2013
|
-
* const tree = await client
|
|
2014
|
-
* .container()
|
|
2015
|
-
* .from("alpine")
|
|
2016
|
-
* .withWorkdir("/foo")
|
|
2017
|
-
* .with(AddAFewMounts)
|
|
2018
|
-
* .withExec(["ls", "-lh"])
|
|
2019
|
-
* .stdout()
|
|
2020
|
-
* })
|
|
2021
|
-
*```
|
|
2022
|
-
*/
|
|
2023
|
-
with(arg) {
|
|
2024
|
-
return arg(this);
|
|
2025
|
-
}
|
|
2026
1893
|
}
|
|
2027
1894
|
/**
|
|
2028
1895
|
* An environment variable on the host environment.
|
|
@@ -2058,30 +1925,6 @@ export class HostVariable extends BaseClient {
|
|
|
2058
1925
|
return response;
|
|
2059
1926
|
});
|
|
2060
1927
|
}
|
|
2061
|
-
/**
|
|
2062
|
-
* Chain objects together
|
|
2063
|
-
* @example
|
|
2064
|
-
* ```ts
|
|
2065
|
-
* function AddAFewMounts(c) {
|
|
2066
|
-
* return c
|
|
2067
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2068
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2069
|
-
* }
|
|
2070
|
-
*
|
|
2071
|
-
* connect(async (client) => {
|
|
2072
|
-
* const tree = await client
|
|
2073
|
-
* .container()
|
|
2074
|
-
* .from("alpine")
|
|
2075
|
-
* .withWorkdir("/foo")
|
|
2076
|
-
* .with(AddAFewMounts)
|
|
2077
|
-
* .withExec(["ls", "-lh"])
|
|
2078
|
-
* .stdout()
|
|
2079
|
-
* })
|
|
2080
|
-
*```
|
|
2081
|
-
*/
|
|
2082
|
-
with(arg) {
|
|
2083
|
-
return arg(this);
|
|
2084
|
-
}
|
|
2085
1928
|
}
|
|
2086
1929
|
/**
|
|
2087
1930
|
* A simple key value object that represents a label.
|
|
@@ -2115,30 +1958,6 @@ export class Label extends BaseClient {
|
|
|
2115
1958
|
return response;
|
|
2116
1959
|
});
|
|
2117
1960
|
}
|
|
2118
|
-
/**
|
|
2119
|
-
* Chain objects together
|
|
2120
|
-
* @example
|
|
2121
|
-
* ```ts
|
|
2122
|
-
* function AddAFewMounts(c) {
|
|
2123
|
-
* return c
|
|
2124
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2125
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2126
|
-
* }
|
|
2127
|
-
*
|
|
2128
|
-
* connect(async (client) => {
|
|
2129
|
-
* const tree = await client
|
|
2130
|
-
* .container()
|
|
2131
|
-
* .from("alpine")
|
|
2132
|
-
* .withWorkdir("/foo")
|
|
2133
|
-
* .with(AddAFewMounts)
|
|
2134
|
-
* .withExec(["ls", "-lh"])
|
|
2135
|
-
* .stdout()
|
|
2136
|
-
* })
|
|
2137
|
-
*```
|
|
2138
|
-
*/
|
|
2139
|
-
with(arg) {
|
|
2140
|
-
return arg(this);
|
|
2141
|
-
}
|
|
2142
1961
|
}
|
|
2143
1962
|
/**
|
|
2144
1963
|
* A port exposed by a container.
|
|
@@ -2186,30 +2005,6 @@ export class Port extends BaseClient {
|
|
|
2186
2005
|
return response;
|
|
2187
2006
|
});
|
|
2188
2007
|
}
|
|
2189
|
-
/**
|
|
2190
|
-
* Chain objects together
|
|
2191
|
-
* @example
|
|
2192
|
-
* ```ts
|
|
2193
|
-
* function AddAFewMounts(c) {
|
|
2194
|
-
* return c
|
|
2195
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2196
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2197
|
-
* }
|
|
2198
|
-
*
|
|
2199
|
-
* connect(async (client) => {
|
|
2200
|
-
* const tree = await client
|
|
2201
|
-
* .container()
|
|
2202
|
-
* .from("alpine")
|
|
2203
|
-
* .withWorkdir("/foo")
|
|
2204
|
-
* .with(AddAFewMounts)
|
|
2205
|
-
* .withExec(["ls", "-lh"])
|
|
2206
|
-
* .stdout()
|
|
2207
|
-
* })
|
|
2208
|
-
*```
|
|
2209
|
-
*/
|
|
2210
|
-
with(arg) {
|
|
2211
|
-
return arg(this);
|
|
2212
|
-
}
|
|
2213
2008
|
}
|
|
2214
2009
|
/**
|
|
2215
2010
|
* A collection of Dagger resources that can be queried and invoked.
|
|
@@ -2274,25 +2069,9 @@ export class Project extends BaseClient {
|
|
|
2274
2069
|
});
|
|
2275
2070
|
}
|
|
2276
2071
|
/**
|
|
2277
|
-
*
|
|
2278
|
-
* @example
|
|
2279
|
-
* ```ts
|
|
2280
|
-
* function AddAFewMounts(c) {
|
|
2281
|
-
* return c
|
|
2282
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2283
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2284
|
-
* }
|
|
2072
|
+
* Call the provided function with current Project.
|
|
2285
2073
|
*
|
|
2286
|
-
*
|
|
2287
|
-
* const tree = await client
|
|
2288
|
-
* .container()
|
|
2289
|
-
* .from("alpine")
|
|
2290
|
-
* .withWorkdir("/foo")
|
|
2291
|
-
* .with(AddAFewMounts)
|
|
2292
|
-
* .withExec(["ls", "-lh"])
|
|
2293
|
-
* .stdout()
|
|
2294
|
-
* })
|
|
2295
|
-
*```
|
|
2074
|
+
* This is useful for reusability and readability by not breaking the calling chain.
|
|
2296
2075
|
*/
|
|
2297
2076
|
with(arg) {
|
|
2298
2077
|
return arg(this);
|
|
@@ -2386,30 +2165,6 @@ export class ProjectCommand extends BaseClient {
|
|
|
2386
2165
|
return response;
|
|
2387
2166
|
});
|
|
2388
2167
|
}
|
|
2389
|
-
/**
|
|
2390
|
-
* Chain objects together
|
|
2391
|
-
* @example
|
|
2392
|
-
* ```ts
|
|
2393
|
-
* function AddAFewMounts(c) {
|
|
2394
|
-
* return c
|
|
2395
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2396
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2397
|
-
* }
|
|
2398
|
-
*
|
|
2399
|
-
* connect(async (client) => {
|
|
2400
|
-
* const tree = await client
|
|
2401
|
-
* .container()
|
|
2402
|
-
* .from("alpine")
|
|
2403
|
-
* .withWorkdir("/foo")
|
|
2404
|
-
* .with(AddAFewMounts)
|
|
2405
|
-
* .withExec(["ls", "-lh"])
|
|
2406
|
-
* .stdout()
|
|
2407
|
-
* })
|
|
2408
|
-
*```
|
|
2409
|
-
*/
|
|
2410
|
-
with(arg) {
|
|
2411
|
-
return arg(this);
|
|
2412
|
-
}
|
|
2413
2168
|
}
|
|
2414
2169
|
/**
|
|
2415
2170
|
* A flag accepted by a project command.
|
|
@@ -2443,30 +2198,6 @@ export class ProjectCommandFlag extends BaseClient {
|
|
|
2443
2198
|
return response;
|
|
2444
2199
|
});
|
|
2445
2200
|
}
|
|
2446
|
-
/**
|
|
2447
|
-
* Chain objects together
|
|
2448
|
-
* @example
|
|
2449
|
-
* ```ts
|
|
2450
|
-
* function AddAFewMounts(c) {
|
|
2451
|
-
* return c
|
|
2452
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2453
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2454
|
-
* }
|
|
2455
|
-
*
|
|
2456
|
-
* connect(async (client) => {
|
|
2457
|
-
* const tree = await client
|
|
2458
|
-
* .container()
|
|
2459
|
-
* .from("alpine")
|
|
2460
|
-
* .withWorkdir("/foo")
|
|
2461
|
-
* .with(AddAFewMounts)
|
|
2462
|
-
* .withExec(["ls", "-lh"])
|
|
2463
|
-
* .stdout()
|
|
2464
|
-
* })
|
|
2465
|
-
*```
|
|
2466
|
-
*/
|
|
2467
|
-
with(arg) {
|
|
2468
|
-
return arg(this);
|
|
2469
|
-
}
|
|
2470
2201
|
}
|
|
2471
2202
|
export default class Client extends BaseClient {
|
|
2472
2203
|
/**
|
|
@@ -2708,6 +2439,14 @@ export default class Client extends BaseClient {
|
|
|
2708
2439
|
sessionToken: this.sessionToken,
|
|
2709
2440
|
});
|
|
2710
2441
|
}
|
|
2442
|
+
/**
|
|
2443
|
+
* Call the provided function with current Client.
|
|
2444
|
+
*
|
|
2445
|
+
* This is useful for reusability and readability by not breaking the calling chain.
|
|
2446
|
+
*/
|
|
2447
|
+
with(arg) {
|
|
2448
|
+
return arg(this);
|
|
2449
|
+
}
|
|
2711
2450
|
}
|
|
2712
2451
|
/**
|
|
2713
2452
|
* A reference to a secret value, which can be handled more safely than the value itself.
|
|
@@ -2741,30 +2480,6 @@ export class Secret extends BaseClient {
|
|
|
2741
2480
|
return response;
|
|
2742
2481
|
});
|
|
2743
2482
|
}
|
|
2744
|
-
/**
|
|
2745
|
-
* Chain objects together
|
|
2746
|
-
* @example
|
|
2747
|
-
* ```ts
|
|
2748
|
-
* function AddAFewMounts(c) {
|
|
2749
|
-
* return c
|
|
2750
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2751
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2752
|
-
* }
|
|
2753
|
-
*
|
|
2754
|
-
* connect(async (client) => {
|
|
2755
|
-
* const tree = await client
|
|
2756
|
-
* .container()
|
|
2757
|
-
* .from("alpine")
|
|
2758
|
-
* .withWorkdir("/foo")
|
|
2759
|
-
* .with(AddAFewMounts)
|
|
2760
|
-
* .withExec(["ls", "-lh"])
|
|
2761
|
-
* .stdout()
|
|
2762
|
-
* })
|
|
2763
|
-
*```
|
|
2764
|
-
*/
|
|
2765
|
-
with(arg) {
|
|
2766
|
-
return arg(this);
|
|
2767
|
-
}
|
|
2768
2483
|
}
|
|
2769
2484
|
export class Socket extends BaseClient {
|
|
2770
2485
|
/**
|
|
@@ -2781,28 +2496,4 @@ export class Socket extends BaseClient {
|
|
|
2781
2496
|
return response;
|
|
2782
2497
|
});
|
|
2783
2498
|
}
|
|
2784
|
-
/**
|
|
2785
|
-
* Chain objects together
|
|
2786
|
-
* @example
|
|
2787
|
-
* ```ts
|
|
2788
|
-
* function AddAFewMounts(c) {
|
|
2789
|
-
* return c
|
|
2790
|
-
* .withMountedDirectory("/foo", new Client().host().directory("/Users/slumbering/forks/dagger"))
|
|
2791
|
-
* .withMountedDirectory("/bar", new Client().host().directory("/Users/slumbering/forks/dagger/sdk/nodejs"))
|
|
2792
|
-
* }
|
|
2793
|
-
*
|
|
2794
|
-
* connect(async (client) => {
|
|
2795
|
-
* const tree = await client
|
|
2796
|
-
* .container()
|
|
2797
|
-
* .from("alpine")
|
|
2798
|
-
* .withWorkdir("/foo")
|
|
2799
|
-
* .with(AddAFewMounts)
|
|
2800
|
-
* .withExec(["ls", "-lh"])
|
|
2801
|
-
* .stdout()
|
|
2802
|
-
* })
|
|
2803
|
-
*```
|
|
2804
|
-
*/
|
|
2805
|
-
with(arg) {
|
|
2806
|
-
return arg(this);
|
|
2807
|
-
}
|
|
2808
2499
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const CLI_VERSION = "0.6.
|
|
1
|
+
export declare const CLI_VERSION = "0.6.4";
|
|
2
2
|
//# sourceMappingURL=default.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Code generated by dagger. DO NOT EDIT.
|
|
2
|
-
export const CLI_VERSION = "0.6.
|
|
2
|
+
export const CLI_VERSION = "0.6.4";
|