@pulumi/docker 4.6.0-beta.2 → 4.6.0-beta.3
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/buildx/image.d.ts +102 -25
- package/buildx/image.js +36 -14
- package/buildx/image.js.map +1 -1
- package/buildx/index.d.ts +3 -0
- package/buildx/index.js +5 -1
- package/buildx/index.js.map +1 -1
- package/buildx/index_.d.ts +140 -0
- package/buildx/index_.js +130 -0
- package/buildx/index_.js.map +1 -0
- package/package.json +1 -1
- package/types/input.d.ts +100 -87
- package/types/input.js +17 -17
- package/types/input.js.map +1 -1
- package/types/output.d.ts +100 -87
- package/types/output.js +17 -17
- package/types/output.js.map +1 -1
package/buildx/image.d.ts
CHANGED
|
@@ -78,7 +78,14 @@ import * as enums from "../types/enums";
|
|
|
78
78
|
*
|
|
79
79
|
* #### Outputs
|
|
80
80
|
*
|
|
81
|
-
*
|
|
81
|
+
* Versions `3.x` and `4.x` of the provider exposed a `repoDigest` output which was a fully qualified tag with digest.
|
|
82
|
+
* In `4.x` this could also be a single sha256 hash if the image wasn't pushed.
|
|
83
|
+
*
|
|
84
|
+
* Unlike earlier providers the `buildx.Image` resource can push multiple tags.
|
|
85
|
+
* As a convenience, it exposes a `ref` output consisting of a tag with digest as long as the image was pushed.
|
|
86
|
+
* If multiple tags were pushed this uses one at random.
|
|
87
|
+
*
|
|
88
|
+
* If you need more control over tag references you can use the `digest` output, which is always a single sha256 hash as long as the image was exported somewhere.
|
|
82
89
|
*
|
|
83
90
|
* #### Tag deletion and refreshes
|
|
84
91
|
*
|
|
@@ -88,7 +95,8 @@ import * as enums from "../types/enums";
|
|
|
88
95
|
* If any are missing a subsequent `update` will push them.
|
|
89
96
|
*
|
|
90
97
|
* When a `buildx.Image` is deleted, it will _attempt_ to also delete any pushed tags.
|
|
91
|
-
* Deletion of remote tags is not guaranteed
|
|
98
|
+
* Deletion of remote tags is not guaranteed because not all registries support the manifest `DELETE` API (`docker.io` in particular).
|
|
99
|
+
* Manifests are _not_ deleted in the same way during updates -- to do so safely would require a full build to determine whether a Pulumi operation should be an update or update-replace.
|
|
92
100
|
*
|
|
93
101
|
* Use the [`retainOnDelete: true`](https://www.pulumi.com/docs/concepts/options/retainondelete/) option if you do not want tags deleted.
|
|
94
102
|
*
|
|
@@ -262,9 +270,6 @@ import * as enums from "../types/enums";
|
|
|
262
270
|
* context: {
|
|
263
271
|
* location: "./app",
|
|
264
272
|
* },
|
|
265
|
-
* dockerfile: {
|
|
266
|
-
* location: "./Dockerfile",
|
|
267
|
-
* },
|
|
268
273
|
* push: true,
|
|
269
274
|
* registries: [{
|
|
270
275
|
* address: ecrRepository.repositoryUrl,
|
|
@@ -273,6 +278,7 @@ import * as enums from "../types/enums";
|
|
|
273
278
|
* }],
|
|
274
279
|
* tags: [pulumi.interpolate`${ecrRepository.repositoryUrl}:latest`],
|
|
275
280
|
* });
|
|
281
|
+
* export const ref = myImage.ref;
|
|
276
282
|
* ```
|
|
277
283
|
* ### Multi-platform image
|
|
278
284
|
*
|
|
@@ -308,6 +314,7 @@ import * as enums from "../types/enums";
|
|
|
308
314
|
* }],
|
|
309
315
|
* tags: ["docker.io/pulumi/pulumi:3.107.0"],
|
|
310
316
|
* });
|
|
317
|
+
* export const ref = myImage.ref;
|
|
311
318
|
* ```
|
|
312
319
|
* ### Caching
|
|
313
320
|
*
|
|
@@ -332,6 +339,22 @@ import * as enums from "../types/enums";
|
|
|
332
339
|
* },
|
|
333
340
|
* });
|
|
334
341
|
* ```
|
|
342
|
+
* ### Docker Build Cloud
|
|
343
|
+
*
|
|
344
|
+
* ```typescript
|
|
345
|
+
* import * as pulumi from "@pulumi/pulumi";
|
|
346
|
+
* import * as docker from "@pulumi/docker";
|
|
347
|
+
*
|
|
348
|
+
* const image = new docker.buildx.Image("image", {
|
|
349
|
+
* builder: {
|
|
350
|
+
* name: "cloud-builder-name",
|
|
351
|
+
* },
|
|
352
|
+
* context: {
|
|
353
|
+
* location: "app",
|
|
354
|
+
* },
|
|
355
|
+
* exec: true,
|
|
356
|
+
* });
|
|
357
|
+
* ```
|
|
335
358
|
* ### Build arguments
|
|
336
359
|
*
|
|
337
360
|
* ```typescript
|
|
@@ -347,7 +370,7 @@ import * as enums from "../types/enums";
|
|
|
347
370
|
* },
|
|
348
371
|
* });
|
|
349
372
|
* ```
|
|
350
|
-
* ### Build
|
|
373
|
+
* ### Build target
|
|
351
374
|
*
|
|
352
375
|
* ```typescript
|
|
353
376
|
* import * as pulumi from "@pulumi/pulumi";
|
|
@@ -357,10 +380,7 @@ import * as enums from "../types/enums";
|
|
|
357
380
|
* context: {
|
|
358
381
|
* location: "app",
|
|
359
382
|
* },
|
|
360
|
-
*
|
|
361
|
-
* "build-me",
|
|
362
|
-
* "also-build-me",
|
|
363
|
-
* ],
|
|
383
|
+
* target: "build-me",
|
|
364
384
|
* });
|
|
365
385
|
* ```
|
|
366
386
|
* ### Named contexts
|
|
@@ -499,13 +519,13 @@ export declare class Image extends pulumi.CustomResource {
|
|
|
499
519
|
*
|
|
500
520
|
* Equivalent to Docker's `--cache-from` flag.
|
|
501
521
|
*/
|
|
502
|
-
readonly cacheFrom: pulumi.Output<outputs.buildx.
|
|
522
|
+
readonly cacheFrom: pulumi.Output<outputs.buildx.CacheFrom[] | undefined>;
|
|
503
523
|
/**
|
|
504
524
|
* Cache import configuration.
|
|
505
525
|
*
|
|
506
526
|
* Equivalent to Docker's `--cache-to` flag.
|
|
507
527
|
*/
|
|
508
|
-
readonly cacheTo: pulumi.Output<outputs.buildx.
|
|
528
|
+
readonly cacheTo: pulumi.Output<outputs.buildx.CacheTo[] | undefined>;
|
|
509
529
|
/**
|
|
510
530
|
* Build context settings.
|
|
511
531
|
*
|
|
@@ -519,30 +539,56 @@ export declare class Image extends pulumi.CustomResource {
|
|
|
519
539
|
*/
|
|
520
540
|
readonly contextHash: pulumi.Output<string>;
|
|
521
541
|
/**
|
|
522
|
-
* A
|
|
542
|
+
* A SHA256 digest of the image if it was exported to a registry or
|
|
543
|
+
* elsewhere.
|
|
523
544
|
*
|
|
524
|
-
*
|
|
545
|
+
* Empty if the image was not exported.
|
|
525
546
|
*
|
|
526
|
-
*
|
|
547
|
+
* Registry images can be referenced precisely as `<tag>@<digest>`. The
|
|
548
|
+
* `ref` output provides one such reference as a convenience.
|
|
527
549
|
*/
|
|
528
|
-
readonly
|
|
529
|
-
[key: string]: string;
|
|
530
|
-
}>;
|
|
550
|
+
readonly digest: pulumi.Output<string>;
|
|
531
551
|
/**
|
|
532
552
|
* Dockerfile settings.
|
|
533
553
|
*
|
|
534
554
|
* Equivalent to Docker's `--file` flag.
|
|
535
555
|
*/
|
|
536
556
|
readonly dockerfile: pulumi.Output<outputs.buildx.Dockerfile | undefined>;
|
|
557
|
+
/**
|
|
558
|
+
* Use `exec` mode to build this image.
|
|
559
|
+
*
|
|
560
|
+
* By default the provider embeds a v25 Docker client with v0.12 buildx
|
|
561
|
+
* support. This helps ensure consistent behavior across environments and
|
|
562
|
+
* is compatible with alternative build backends (e.g. `buildkitd`), but
|
|
563
|
+
* it may not be desirable if you require a specific version of buildx.
|
|
564
|
+
* For example you may want to run a custom `docker-buildx` binary with
|
|
565
|
+
* support for [Docker Build
|
|
566
|
+
* Cloud](https://docs.docker.com/build/cloud/setup/) (DBC).
|
|
567
|
+
*
|
|
568
|
+
* When this is set to `true` the provider will instead execute the
|
|
569
|
+
* `docker-buildx` binary directly to perform its operations. The user is
|
|
570
|
+
* responsible for ensuring this binary exists, with correct permissions
|
|
571
|
+
* and pre-configured builders, at a path Docker expects (e.g.
|
|
572
|
+
* `~/.docker/cli-plugins`).
|
|
573
|
+
*
|
|
574
|
+
* Debugging `exec` mode may be more difficult as Pulumi will not be able
|
|
575
|
+
* to surface fine-grained errors and warnings. Additionally credentials
|
|
576
|
+
* are temporarily written to disk in order to provide them to the
|
|
577
|
+
* `docker-buildx` binary.
|
|
578
|
+
*/
|
|
579
|
+
readonly exec: pulumi.Output<boolean | undefined>;
|
|
537
580
|
/**
|
|
538
581
|
* Controls where images are persisted after building.
|
|
539
582
|
*
|
|
540
583
|
* Images are only stored in the local cache unless `exports` are
|
|
541
584
|
* explicitly configured.
|
|
542
585
|
*
|
|
586
|
+
* Exporting to multiple destinations requires a daemon running BuildKit
|
|
587
|
+
* 0.13 or later.
|
|
588
|
+
*
|
|
543
589
|
* Equivalent to Docker's `--output` flag.
|
|
544
590
|
*/
|
|
545
|
-
readonly exports: pulumi.Output<outputs.buildx.
|
|
591
|
+
readonly exports: pulumi.Output<outputs.buildx.Export[] | undefined>;
|
|
546
592
|
/**
|
|
547
593
|
* Attach arbitrary key/value metadata to the image.
|
|
548
594
|
*
|
|
@@ -597,12 +643,17 @@ export declare class Image extends pulumi.CustomResource {
|
|
|
597
643
|
* If the image was pushed to any registries then this will contain a
|
|
598
644
|
* single fully-qualified tag including the build's digest.
|
|
599
645
|
*
|
|
646
|
+
* If the image had tags but was not exported, this will take on a value
|
|
647
|
+
* of one of those tags.
|
|
648
|
+
*
|
|
649
|
+
* This will be empty if the image had no exports and no tags.
|
|
650
|
+
*
|
|
600
651
|
* This is only for convenience and may not be appropriate for situations
|
|
601
652
|
* where multiple tags or registries are involved. In those cases this
|
|
602
653
|
* output is not guaranteed to be stable.
|
|
603
654
|
*
|
|
604
655
|
* For more control over tags consumed by downstream resources you should
|
|
605
|
-
* use the `
|
|
656
|
+
* use the `digest` output.
|
|
606
657
|
*/
|
|
607
658
|
readonly ref: pulumi.Output<string>;
|
|
608
659
|
/**
|
|
@@ -651,7 +702,7 @@ export declare class Image extends pulumi.CustomResource {
|
|
|
651
702
|
*
|
|
652
703
|
* Equivalent to Docker's `--target` flag.
|
|
653
704
|
*/
|
|
654
|
-
readonly
|
|
705
|
+
readonly target: pulumi.Output<string | undefined>;
|
|
655
706
|
/**
|
|
656
707
|
* Create a Image resource with the given unique name, arguments, and options.
|
|
657
708
|
*
|
|
@@ -711,13 +762,13 @@ export interface ImageArgs {
|
|
|
711
762
|
*
|
|
712
763
|
* Equivalent to Docker's `--cache-from` flag.
|
|
713
764
|
*/
|
|
714
|
-
cacheFrom?: pulumi.Input<pulumi.Input<inputs.buildx.
|
|
765
|
+
cacheFrom?: pulumi.Input<pulumi.Input<inputs.buildx.CacheFrom>[]>;
|
|
715
766
|
/**
|
|
716
767
|
* Cache import configuration.
|
|
717
768
|
*
|
|
718
769
|
* Equivalent to Docker's `--cache-to` flag.
|
|
719
770
|
*/
|
|
720
|
-
cacheTo?: pulumi.Input<pulumi.Input<inputs.buildx.
|
|
771
|
+
cacheTo?: pulumi.Input<pulumi.Input<inputs.buildx.CacheTo>[]>;
|
|
721
772
|
/**
|
|
722
773
|
* Build context settings.
|
|
723
774
|
*
|
|
@@ -730,15 +781,41 @@ export interface ImageArgs {
|
|
|
730
781
|
* Equivalent to Docker's `--file` flag.
|
|
731
782
|
*/
|
|
732
783
|
dockerfile?: pulumi.Input<inputs.buildx.Dockerfile>;
|
|
784
|
+
/**
|
|
785
|
+
* Use `exec` mode to build this image.
|
|
786
|
+
*
|
|
787
|
+
* By default the provider embeds a v25 Docker client with v0.12 buildx
|
|
788
|
+
* support. This helps ensure consistent behavior across environments and
|
|
789
|
+
* is compatible with alternative build backends (e.g. `buildkitd`), but
|
|
790
|
+
* it may not be desirable if you require a specific version of buildx.
|
|
791
|
+
* For example you may want to run a custom `docker-buildx` binary with
|
|
792
|
+
* support for [Docker Build
|
|
793
|
+
* Cloud](https://docs.docker.com/build/cloud/setup/) (DBC).
|
|
794
|
+
*
|
|
795
|
+
* When this is set to `true` the provider will instead execute the
|
|
796
|
+
* `docker-buildx` binary directly to perform its operations. The user is
|
|
797
|
+
* responsible for ensuring this binary exists, with correct permissions
|
|
798
|
+
* and pre-configured builders, at a path Docker expects (e.g.
|
|
799
|
+
* `~/.docker/cli-plugins`).
|
|
800
|
+
*
|
|
801
|
+
* Debugging `exec` mode may be more difficult as Pulumi will not be able
|
|
802
|
+
* to surface fine-grained errors and warnings. Additionally credentials
|
|
803
|
+
* are temporarily written to disk in order to provide them to the
|
|
804
|
+
* `docker-buildx` binary.
|
|
805
|
+
*/
|
|
806
|
+
exec?: pulumi.Input<boolean>;
|
|
733
807
|
/**
|
|
734
808
|
* Controls where images are persisted after building.
|
|
735
809
|
*
|
|
736
810
|
* Images are only stored in the local cache unless `exports` are
|
|
737
811
|
* explicitly configured.
|
|
738
812
|
*
|
|
813
|
+
* Exporting to multiple destinations requires a daemon running BuildKit
|
|
814
|
+
* 0.13 or later.
|
|
815
|
+
*
|
|
739
816
|
* Equivalent to Docker's `--output` flag.
|
|
740
817
|
*/
|
|
741
|
-
exports?: pulumi.Input<pulumi.Input<inputs.buildx.
|
|
818
|
+
exports?: pulumi.Input<pulumi.Input<inputs.buildx.Export>[]>;
|
|
742
819
|
/**
|
|
743
820
|
* Attach arbitrary key/value metadata to the image.
|
|
744
821
|
*
|
|
@@ -835,5 +912,5 @@ export interface ImageArgs {
|
|
|
835
912
|
*
|
|
836
913
|
* Equivalent to Docker's `--target` flag.
|
|
837
914
|
*/
|
|
838
|
-
|
|
915
|
+
target?: pulumi.Input<string>;
|
|
839
916
|
}
|
package/buildx/image.js
CHANGED
|
@@ -81,7 +81,14 @@ const utilities = require("../utilities");
|
|
|
81
81
|
*
|
|
82
82
|
* #### Outputs
|
|
83
83
|
*
|
|
84
|
-
*
|
|
84
|
+
* Versions `3.x` and `4.x` of the provider exposed a `repoDigest` output which was a fully qualified tag with digest.
|
|
85
|
+
* In `4.x` this could also be a single sha256 hash if the image wasn't pushed.
|
|
86
|
+
*
|
|
87
|
+
* Unlike earlier providers the `buildx.Image` resource can push multiple tags.
|
|
88
|
+
* As a convenience, it exposes a `ref` output consisting of a tag with digest as long as the image was pushed.
|
|
89
|
+
* If multiple tags were pushed this uses one at random.
|
|
90
|
+
*
|
|
91
|
+
* If you need more control over tag references you can use the `digest` output, which is always a single sha256 hash as long as the image was exported somewhere.
|
|
85
92
|
*
|
|
86
93
|
* #### Tag deletion and refreshes
|
|
87
94
|
*
|
|
@@ -91,7 +98,8 @@ const utilities = require("../utilities");
|
|
|
91
98
|
* If any are missing a subsequent `update` will push them.
|
|
92
99
|
*
|
|
93
100
|
* When a `buildx.Image` is deleted, it will _attempt_ to also delete any pushed tags.
|
|
94
|
-
* Deletion of remote tags is not guaranteed
|
|
101
|
+
* Deletion of remote tags is not guaranteed because not all registries support the manifest `DELETE` API (`docker.io` in particular).
|
|
102
|
+
* Manifests are _not_ deleted in the same way during updates -- to do so safely would require a full build to determine whether a Pulumi operation should be an update or update-replace.
|
|
95
103
|
*
|
|
96
104
|
* Use the [`retainOnDelete: true`](https://www.pulumi.com/docs/concepts/options/retainondelete/) option if you do not want tags deleted.
|
|
97
105
|
*
|
|
@@ -265,9 +273,6 @@ const utilities = require("../utilities");
|
|
|
265
273
|
* context: {
|
|
266
274
|
* location: "./app",
|
|
267
275
|
* },
|
|
268
|
-
* dockerfile: {
|
|
269
|
-
* location: "./Dockerfile",
|
|
270
|
-
* },
|
|
271
276
|
* push: true,
|
|
272
277
|
* registries: [{
|
|
273
278
|
* address: ecrRepository.repositoryUrl,
|
|
@@ -276,6 +281,7 @@ const utilities = require("../utilities");
|
|
|
276
281
|
* }],
|
|
277
282
|
* tags: [pulumi.interpolate`${ecrRepository.repositoryUrl}:latest`],
|
|
278
283
|
* });
|
|
284
|
+
* export const ref = myImage.ref;
|
|
279
285
|
* ```
|
|
280
286
|
* ### Multi-platform image
|
|
281
287
|
*
|
|
@@ -311,6 +317,7 @@ const utilities = require("../utilities");
|
|
|
311
317
|
* }],
|
|
312
318
|
* tags: ["docker.io/pulumi/pulumi:3.107.0"],
|
|
313
319
|
* });
|
|
320
|
+
* export const ref = myImage.ref;
|
|
314
321
|
* ```
|
|
315
322
|
* ### Caching
|
|
316
323
|
*
|
|
@@ -335,6 +342,22 @@ const utilities = require("../utilities");
|
|
|
335
342
|
* },
|
|
336
343
|
* });
|
|
337
344
|
* ```
|
|
345
|
+
* ### Docker Build Cloud
|
|
346
|
+
*
|
|
347
|
+
* ```typescript
|
|
348
|
+
* import * as pulumi from "@pulumi/pulumi";
|
|
349
|
+
* import * as docker from "@pulumi/docker";
|
|
350
|
+
*
|
|
351
|
+
* const image = new docker.buildx.Image("image", {
|
|
352
|
+
* builder: {
|
|
353
|
+
* name: "cloud-builder-name",
|
|
354
|
+
* },
|
|
355
|
+
* context: {
|
|
356
|
+
* location: "app",
|
|
357
|
+
* },
|
|
358
|
+
* exec: true,
|
|
359
|
+
* });
|
|
360
|
+
* ```
|
|
338
361
|
* ### Build arguments
|
|
339
362
|
*
|
|
340
363
|
* ```typescript
|
|
@@ -350,7 +373,7 @@ const utilities = require("../utilities");
|
|
|
350
373
|
* },
|
|
351
374
|
* });
|
|
352
375
|
* ```
|
|
353
|
-
* ### Build
|
|
376
|
+
* ### Build target
|
|
354
377
|
*
|
|
355
378
|
* ```typescript
|
|
356
379
|
* import * as pulumi from "@pulumi/pulumi";
|
|
@@ -360,10 +383,7 @@ const utilities = require("../utilities");
|
|
|
360
383
|
* context: {
|
|
361
384
|
* location: "app",
|
|
362
385
|
* },
|
|
363
|
-
*
|
|
364
|
-
* "build-me",
|
|
365
|
-
* "also-build-me",
|
|
366
|
-
* ],
|
|
386
|
+
* target: "build-me",
|
|
367
387
|
* });
|
|
368
388
|
* ```
|
|
369
389
|
* ### Named contexts
|
|
@@ -483,6 +503,7 @@ class Image extends pulumi.CustomResource {
|
|
|
483
503
|
resourceInputs["cacheTo"] = args ? args.cacheTo : undefined;
|
|
484
504
|
resourceInputs["context"] = args ? args.context : undefined;
|
|
485
505
|
resourceInputs["dockerfile"] = args ? args.dockerfile : undefined;
|
|
506
|
+
resourceInputs["exec"] = args ? args.exec : undefined;
|
|
486
507
|
resourceInputs["exports"] = args ? args.exports : undefined;
|
|
487
508
|
resourceInputs["labels"] = args ? args.labels : undefined;
|
|
488
509
|
resourceInputs["load"] = args ? args.load : undefined;
|
|
@@ -495,9 +516,9 @@ class Image extends pulumi.CustomResource {
|
|
|
495
516
|
resourceInputs["secrets"] = args ? args.secrets : undefined;
|
|
496
517
|
resourceInputs["ssh"] = args ? args.ssh : undefined;
|
|
497
518
|
resourceInputs["tags"] = args ? args.tags : undefined;
|
|
498
|
-
resourceInputs["
|
|
519
|
+
resourceInputs["target"] = args ? args.target : undefined;
|
|
499
520
|
resourceInputs["contextHash"] = undefined /*out*/;
|
|
500
|
-
resourceInputs["
|
|
521
|
+
resourceInputs["digest"] = undefined /*out*/;
|
|
501
522
|
resourceInputs["ref"] = undefined /*out*/;
|
|
502
523
|
}
|
|
503
524
|
else {
|
|
@@ -509,8 +530,9 @@ class Image extends pulumi.CustomResource {
|
|
|
509
530
|
resourceInputs["cacheTo"] = undefined /*out*/;
|
|
510
531
|
resourceInputs["context"] = undefined /*out*/;
|
|
511
532
|
resourceInputs["contextHash"] = undefined /*out*/;
|
|
512
|
-
resourceInputs["
|
|
533
|
+
resourceInputs["digest"] = undefined /*out*/;
|
|
513
534
|
resourceInputs["dockerfile"] = undefined /*out*/;
|
|
535
|
+
resourceInputs["exec"] = undefined /*out*/;
|
|
514
536
|
resourceInputs["exports"] = undefined /*out*/;
|
|
515
537
|
resourceInputs["labels"] = undefined /*out*/;
|
|
516
538
|
resourceInputs["load"] = undefined /*out*/;
|
|
@@ -524,7 +546,7 @@ class Image extends pulumi.CustomResource {
|
|
|
524
546
|
resourceInputs["secrets"] = undefined /*out*/;
|
|
525
547
|
resourceInputs["ssh"] = undefined /*out*/;
|
|
526
548
|
resourceInputs["tags"] = undefined /*out*/;
|
|
527
|
-
resourceInputs["
|
|
549
|
+
resourceInputs["target"] = undefined /*out*/;
|
|
528
550
|
}
|
|
529
551
|
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
530
552
|
super(Image.__pulumiType, name, resourceInputs, opts);
|
package/buildx/image.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"image.js","sourceRoot":"","sources":["../../buildx/image.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,i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YAC9C,cAAc,CAAC,SAAS,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC9C,cAAc,CAAC,WAAW,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAChD,cAAc,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC3C,cAAc,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC3C,cAAc,CAAC,KAAK,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC1C,cAAc,CAAC,YAAY,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YACjD,cAAc,CAAC,SAAS,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC9C,cAAc,CAAC,KAAK,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC1C,cAAc,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC3C,cAAc,CAAC,QAAQ,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;SAChD;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,KAAK,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IAC1D,CAAC;;AA7TL,sBA8TC;AAjTG,gBAAgB;AACO,kBAAY,GAAG,2BAA2B,CAAC"}
|
package/buildx/index.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
export { ImageArgs } from "./image";
|
|
2
2
|
export type Image = import("./image").Image;
|
|
3
3
|
export declare const Image: typeof import("./image").Image;
|
|
4
|
+
export { IndexArgs } from "./index_";
|
|
5
|
+
export type Index = import("./index_").Index;
|
|
6
|
+
export declare const Index: typeof import("./index_").Index;
|
|
4
7
|
export * from "../types/enums/buildx";
|
package/buildx/index.js
CHANGED
|
@@ -16,11 +16,13 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
17
17
|
};
|
|
18
18
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
-
exports.Image = void 0;
|
|
19
|
+
exports.Index = exports.Image = void 0;
|
|
20
20
|
const pulumi = require("@pulumi/pulumi");
|
|
21
21
|
const utilities = require("../utilities");
|
|
22
22
|
exports.Image = null;
|
|
23
23
|
utilities.lazyLoad(exports, ["Image"], () => require("./image"));
|
|
24
|
+
exports.Index = null;
|
|
25
|
+
utilities.lazyLoad(exports, ["Index"], () => require("./index_"));
|
|
24
26
|
// Export enums:
|
|
25
27
|
__exportStar(require("../types/enums/buildx"), exports);
|
|
26
28
|
const _module = {
|
|
@@ -29,6 +31,8 @@ const _module = {
|
|
|
29
31
|
switch (type) {
|
|
30
32
|
case "docker:buildx/image:Image":
|
|
31
33
|
return new exports.Image(name, undefined, { urn });
|
|
34
|
+
case "docker:buildx/image:Index":
|
|
35
|
+
return new exports.Index(name, undefined, { urn });
|
|
32
36
|
default:
|
|
33
37
|
throw new Error(`unknown resource type ${type}`);
|
|
34
38
|
}
|
package/buildx/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../buildx/index.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;;;;;;;;;;;;;;;AAEjF,yCAAyC;AACzC,0CAA0C;AAK7B,QAAA,KAAK,GAAmC,IAAW,CAAC;AACjE,SAAS,CAAC,QAAQ,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../buildx/index.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;;;;;;;;;;;;;;;AAEjF,yCAAyC;AACzC,0CAA0C;AAK7B,QAAA,KAAK,GAAmC,IAAW,CAAC;AACjE,SAAS,CAAC,QAAQ,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC;AAIpD,QAAA,KAAK,GAAoC,IAAW,CAAC;AAClE,SAAS,CAAC,QAAQ,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;AAGlE,gBAAgB;AAChB,wDAAsC;AAEtC,MAAM,OAAO,GAAG;IACZ,OAAO,EAAE,SAAS,CAAC,UAAU,EAAE;IAC/B,SAAS,EAAE,CAAC,IAAY,EAAE,IAAY,EAAE,GAAW,EAAmB,EAAE;QACpE,QAAQ,IAAI,EAAE;YACV,KAAK,2BAA2B;gBAC5B,OAAO,IAAI,aAAK,CAAC,IAAI,EAAO,SAAS,EAAE,EAAE,GAAG,EAAE,CAAC,CAAA;YACnD,KAAK,2BAA2B;gBAC5B,OAAO,IAAI,aAAK,CAAC,IAAI,EAAO,SAAS,EAAE,EAAE,GAAG,EAAE,CAAC,CAAA;YACnD;gBACI,MAAM,IAAI,KAAK,CAAC,yBAAyB,IAAI,EAAE,CAAC,CAAC;SACxD;IACL,CAAC;CACJ,CAAC;AACF,MAAM,CAAC,OAAO,CAAC,sBAAsB,CAAC,QAAQ,EAAE,cAAc,EAAE,OAAO,CAAC,CAAA"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
import * as inputs from "../types/input";
|
|
3
|
+
import * as outputs from "../types/output";
|
|
4
|
+
/**
|
|
5
|
+
* An index (or manifest list) referencing one or more existing images.
|
|
6
|
+
*
|
|
7
|
+
* Useful for crafting a multi-platform image from several
|
|
8
|
+
* platform-specific images.
|
|
9
|
+
*
|
|
10
|
+
* This creates an OCI image index or a Docker manifest list depending on
|
|
11
|
+
* the media types of the source images.
|
|
12
|
+
*
|
|
13
|
+
* ## Example Usage
|
|
14
|
+
* ### Multi-platform registry caching
|
|
15
|
+
*
|
|
16
|
+
* ```typescript
|
|
17
|
+
* import * as pulumi from "@pulumi/pulumi";
|
|
18
|
+
* import * as docker from "@pulumi/docker";
|
|
19
|
+
*
|
|
20
|
+
* const amd64 = new docker.buildx.Image("amd64", {
|
|
21
|
+
* cacheFrom: [{
|
|
22
|
+
* registry: {
|
|
23
|
+
* ref: "docker.io/pulumi/pulumi:cache-amd64",
|
|
24
|
+
* },
|
|
25
|
+
* }],
|
|
26
|
+
* cacheTo: [{
|
|
27
|
+
* registry: {
|
|
28
|
+
* mode: docker.buildx.image.CacheMode.Max,
|
|
29
|
+
* ref: "docker.io/pulumi/pulumi:cache-amd64",
|
|
30
|
+
* },
|
|
31
|
+
* }],
|
|
32
|
+
* context: {
|
|
33
|
+
* location: "app",
|
|
34
|
+
* },
|
|
35
|
+
* platforms: [docker.buildx.image.Platform.Linux_amd64],
|
|
36
|
+
* tags: ["docker.io/pulumi/pulumi:3.107.0-amd64"],
|
|
37
|
+
* });
|
|
38
|
+
* const arm64 = new docker.buildx.Image("arm64", {
|
|
39
|
+
* cacheFrom: [{
|
|
40
|
+
* registry: {
|
|
41
|
+
* ref: "docker.io/pulumi/pulumi:cache-arm64",
|
|
42
|
+
* },
|
|
43
|
+
* }],
|
|
44
|
+
* cacheTo: [{
|
|
45
|
+
* registry: {
|
|
46
|
+
* mode: docker.buildx.image.CacheMode.Max,
|
|
47
|
+
* ref: "docker.io/pulumi/pulumi:cache-arm64",
|
|
48
|
+
* },
|
|
49
|
+
* }],
|
|
50
|
+
* context: {
|
|
51
|
+
* location: "app",
|
|
52
|
+
* },
|
|
53
|
+
* platforms: [docker.buildx.image.Platform.Linux_arm64],
|
|
54
|
+
* tags: ["docker.io/pulumi/pulumi:3.107.0-arm64"],
|
|
55
|
+
* });
|
|
56
|
+
* const index = new docker.buildx.Index("index", {
|
|
57
|
+
* sources: [
|
|
58
|
+
* amd64.ref,
|
|
59
|
+
* arm64.ref,
|
|
60
|
+
* ],
|
|
61
|
+
* tag: "docker.io/pulumi/pulumi:3.107.0",
|
|
62
|
+
* });
|
|
63
|
+
* export const ref = index.ref;
|
|
64
|
+
* ```
|
|
65
|
+
*/
|
|
66
|
+
export declare class Index extends pulumi.CustomResource {
|
|
67
|
+
/**
|
|
68
|
+
* Get an existing Index resource's state with the given name, ID, and optional extra
|
|
69
|
+
* properties used to qualify the lookup.
|
|
70
|
+
*
|
|
71
|
+
* @param name The _unique_ name of the resulting resource.
|
|
72
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
73
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
74
|
+
*/
|
|
75
|
+
static get(name: string, id: pulumi.Input<pulumi.ID>, opts?: pulumi.CustomResourceOptions): Index;
|
|
76
|
+
/**
|
|
77
|
+
* Returns true if the given object is an instance of Index. This is designed to work even
|
|
78
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
79
|
+
*/
|
|
80
|
+
static isInstance(obj: any): obj is Index;
|
|
81
|
+
/**
|
|
82
|
+
* If true, push the index to the target registry.
|
|
83
|
+
*
|
|
84
|
+
* Defaults to `true`.
|
|
85
|
+
*/
|
|
86
|
+
readonly push: pulumi.Output<boolean | undefined>;
|
|
87
|
+
/**
|
|
88
|
+
* The pushed tag with digest.
|
|
89
|
+
*
|
|
90
|
+
* Identical to the tag if the index was not pushed.
|
|
91
|
+
*/
|
|
92
|
+
readonly ref: pulumi.Output<string>;
|
|
93
|
+
/**
|
|
94
|
+
* Authentication for the registry where the tagged index will be pushed.
|
|
95
|
+
*
|
|
96
|
+
* Credentials can also be included with the provider's configuration.
|
|
97
|
+
*/
|
|
98
|
+
readonly registry: pulumi.Output<outputs.buildx.RegistryAuth | undefined>;
|
|
99
|
+
/**
|
|
100
|
+
* Existing images to include in the index.
|
|
101
|
+
*/
|
|
102
|
+
readonly sources: pulumi.Output<string[]>;
|
|
103
|
+
/**
|
|
104
|
+
* The tag to apply to the index.
|
|
105
|
+
*/
|
|
106
|
+
readonly tag: pulumi.Output<string>;
|
|
107
|
+
/**
|
|
108
|
+
* Create a Index resource with the given unique name, arguments, and options.
|
|
109
|
+
*
|
|
110
|
+
* @param name The _unique_ name of the resource.
|
|
111
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
112
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
113
|
+
*/
|
|
114
|
+
constructor(name: string, args: IndexArgs, opts?: pulumi.CustomResourceOptions);
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* The set of arguments for constructing a Index resource.
|
|
118
|
+
*/
|
|
119
|
+
export interface IndexArgs {
|
|
120
|
+
/**
|
|
121
|
+
* If true, push the index to the target registry.
|
|
122
|
+
*
|
|
123
|
+
* Defaults to `true`.
|
|
124
|
+
*/
|
|
125
|
+
push?: pulumi.Input<boolean>;
|
|
126
|
+
/**
|
|
127
|
+
* Authentication for the registry where the tagged index will be pushed.
|
|
128
|
+
*
|
|
129
|
+
* Credentials can also be included with the provider's configuration.
|
|
130
|
+
*/
|
|
131
|
+
registry?: pulumi.Input<inputs.buildx.RegistryAuth>;
|
|
132
|
+
/**
|
|
133
|
+
* Existing images to include in the index.
|
|
134
|
+
*/
|
|
135
|
+
sources: pulumi.Input<pulumi.Input<string>[]>;
|
|
136
|
+
/**
|
|
137
|
+
* The tag to apply to the index.
|
|
138
|
+
*/
|
|
139
|
+
tag: pulumi.Input<string>;
|
|
140
|
+
}
|