pulumi-docker-build 0.0.1__tar.gz → 0.0.1a3__tar.gz
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.
Potentially problematic release.
This version of pulumi-docker-build might be problematic. Click here for more details.
- pulumi_docker_build-0.0.1a3/PKG-INFO +120 -0
- pulumi_docker_build-0.0.1a3/README.md +106 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/_utilities.py +1 -1
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/image.py +172 -148
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/index.py +10 -34
- pulumi_docker_build-0.0.1a3/pulumi_docker_build/pulumi-plugin.json +5 -0
- pulumi_docker_build-0.0.1a3/pulumi_docker_build.egg-info/PKG-INFO +120 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pyproject.toml +4 -4
- pulumi_docker_build-0.0.1/PKG-INFO +0 -37
- pulumi_docker_build-0.0.1/README.md +0 -23
- pulumi_docker_build-0.0.1/pulumi_docker_build/pulumi-plugin.json +0 -4
- pulumi_docker_build-0.0.1/pulumi_docker_build.egg-info/PKG-INFO +0 -37
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/__init__.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/_enums.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/_inputs.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/config/__init__.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/config/__init__.pyi +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/config/vars.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/outputs.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/provider.py +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build/py.typed +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build.egg-info/SOURCES.txt +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build.egg-info/dependency_links.txt +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build.egg-info/requires.txt +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/pulumi_docker_build.egg-info/top_level.txt +0 -0
- {pulumi_docker_build-0.0.1 → pulumi_docker_build-0.0.1a3}/setup.cfg +0 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: pulumi_docker_build
|
|
3
|
+
Version: 0.0.1a3
|
|
4
|
+
Summary: A Pulumi provider for Docker buildx
|
|
5
|
+
License: Apache-2.0
|
|
6
|
+
Project-URL: Homepage, https://pulumi.io
|
|
7
|
+
Project-URL: Repository, https://github.com/pulumi/pulumi-docker-build
|
|
8
|
+
Keywords: docker,buildkit,buildx
|
|
9
|
+
Requires-Python: >=3.8
|
|
10
|
+
Description-Content-Type: text/markdown
|
|
11
|
+
Requires-Dist: parver>=0.2.1
|
|
12
|
+
Requires-Dist: pulumi<4.0.0,>=3.0.0
|
|
13
|
+
Requires-Dist: semver>=2.8.1
|
|
14
|
+
|
|
15
|
+
# Pulumi Native Provider Boilerplate
|
|
16
|
+
|
|
17
|
+
This repository is a boilerplate showing how to create and locally test a native Pulumi provider.
|
|
18
|
+
|
|
19
|
+
## Authoring a Pulumi Native Provider
|
|
20
|
+
|
|
21
|
+
This boilerplate creates a working Pulumi-owned provider named `xyz`.
|
|
22
|
+
It implements a random number generator that you can [build and test out for yourself](#test-against-the-example) and then replace the Random code with code specific to your provider.
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Prerequisites
|
|
26
|
+
|
|
27
|
+
Prerequisites for this repository are already satisfied by the [Pulumi Devcontainer](https://github.com/pulumi/devcontainer) if you are using Github Codespaces, or VSCode.
|
|
28
|
+
|
|
29
|
+
If you are not using VSCode, you will need to ensure the following tools are installed and present in your `$PATH`:
|
|
30
|
+
|
|
31
|
+
* [`pulumictl`](https://github.com/pulumi/pulumictl#installation)
|
|
32
|
+
* [Go 1.21](https://golang.org/dl/) or 1.latest
|
|
33
|
+
* [NodeJS](https://nodejs.org/en/) 14.x. We recommend using [nvm](https://github.com/nvm-sh/nvm) to manage NodeJS installations.
|
|
34
|
+
* [Yarn](https://yarnpkg.com/)
|
|
35
|
+
* [TypeScript](https://www.typescriptlang.org/)
|
|
36
|
+
* [Python](https://www.python.org/downloads/) (called as `python3`). For recent versions of MacOS, the system-installed version is fine.
|
|
37
|
+
* [.NET](https://dotnet.microsoft.com/download)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
### Build & test the boilerplate XYZ provider
|
|
41
|
+
|
|
42
|
+
1. Create a new Github CodeSpaces environment using this repository.
|
|
43
|
+
1. Open a terminal in the CodeSpaces environment.
|
|
44
|
+
1. Run `make build install` to build and install the provider.
|
|
45
|
+
1. Run `make gen_examples` to generate the example programs in `examples/` off of the source `examples/yaml` example program.
|
|
46
|
+
1. Run `make up` to run the example program in `examples/yaml`.
|
|
47
|
+
1. Run `make down` to tear down the example program.
|
|
48
|
+
|
|
49
|
+
### Creating a new provider repository
|
|
50
|
+
|
|
51
|
+
Pulumi offers this repository as a [GitHub template repository](https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-repository-from-a-template) for convenience. From this repository:
|
|
52
|
+
|
|
53
|
+
1. Click "Use this template".
|
|
54
|
+
1. Set the following options:
|
|
55
|
+
* Owner: pulumi
|
|
56
|
+
* Repository name: pulumi-xyz-native (replace "xyz" with the name of your provider)
|
|
57
|
+
* Description: Pulumi provider for xyz
|
|
58
|
+
* Repository type: Public
|
|
59
|
+
1. Clone the generated repository.
|
|
60
|
+
|
|
61
|
+
From the templated repository:
|
|
62
|
+
|
|
63
|
+
1. Search-replace `xyz` with the name of your desired provider.
|
|
64
|
+
|
|
65
|
+
#### Build the provider and install the plugin
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
$ make build install
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
This will:
|
|
72
|
+
|
|
73
|
+
1. Create the SDK codegen binary and place it in a `./bin` folder (gitignored)
|
|
74
|
+
2. Create the provider binary and place it in the `./bin` folder (gitignored)
|
|
75
|
+
3. Generate the dotnet, Go, Node, and Python SDKs and place them in the `./sdk` folder
|
|
76
|
+
4. Install the provider on your machine.
|
|
77
|
+
|
|
78
|
+
#### Test against the example
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
$ cd examples/simple
|
|
82
|
+
$ yarn link @pulumi/xyz
|
|
83
|
+
$ yarn install
|
|
84
|
+
$ pulumi stack init test
|
|
85
|
+
$ pulumi up
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Now that you have completed all of the above steps, you have a working provider that generates a random string for you.
|
|
89
|
+
|
|
90
|
+
#### A brief repository overview
|
|
91
|
+
|
|
92
|
+
You now have:
|
|
93
|
+
|
|
94
|
+
1. A `provider/` folder containing the building and implementation logic
|
|
95
|
+
1. `cmd/pulumi-resource-xyz/main.go` - holds the provider's sample implementation logic.
|
|
96
|
+
2. `deployment-templates` - a set of files to help you around deployment and publication
|
|
97
|
+
3. `sdk` - holds the generated code libraries created by `pulumi-gen-xyz/main.go`
|
|
98
|
+
4. `examples` a folder of Pulumi programs to try locally and/or use in CI.
|
|
99
|
+
5. A `Makefile` and this `README`.
|
|
100
|
+
|
|
101
|
+
#### Additional Details
|
|
102
|
+
|
|
103
|
+
This repository depends on the pulumi-go-provider library. For more details on building providers, please check
|
|
104
|
+
the [Pulumi Go Provider docs](https://github.com/pulumi/pulumi-go-provider).
|
|
105
|
+
|
|
106
|
+
### Build Examples
|
|
107
|
+
|
|
108
|
+
Create an example program using the resources defined in your provider, and place it in the `examples/` folder.
|
|
109
|
+
|
|
110
|
+
You can now repeat the steps for [build, install, and test](#test-against-the-example).
|
|
111
|
+
|
|
112
|
+
## Configuring CI and releases
|
|
113
|
+
|
|
114
|
+
1. Follow the instructions laid out in the [deployment templates](./deployment-templates/README-DEPLOYMENT.md).
|
|
115
|
+
|
|
116
|
+
## References
|
|
117
|
+
|
|
118
|
+
Other resources/examples for implementing providers:
|
|
119
|
+
* [Pulumi Command provider](https://github.com/pulumi/pulumi-command/blob/master/provider/pkg/provider/provider.go)
|
|
120
|
+
* [Pulumi Go Provider repository](https://github.com/pulumi/pulumi-go-provider)
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
# Pulumi Native Provider Boilerplate
|
|
2
|
+
|
|
3
|
+
This repository is a boilerplate showing how to create and locally test a native Pulumi provider.
|
|
4
|
+
|
|
5
|
+
## Authoring a Pulumi Native Provider
|
|
6
|
+
|
|
7
|
+
This boilerplate creates a working Pulumi-owned provider named `xyz`.
|
|
8
|
+
It implements a random number generator that you can [build and test out for yourself](#test-against-the-example) and then replace the Random code with code specific to your provider.
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Prerequisites
|
|
12
|
+
|
|
13
|
+
Prerequisites for this repository are already satisfied by the [Pulumi Devcontainer](https://github.com/pulumi/devcontainer) if you are using Github Codespaces, or VSCode.
|
|
14
|
+
|
|
15
|
+
If you are not using VSCode, you will need to ensure the following tools are installed and present in your `$PATH`:
|
|
16
|
+
|
|
17
|
+
* [`pulumictl`](https://github.com/pulumi/pulumictl#installation)
|
|
18
|
+
* [Go 1.21](https://golang.org/dl/) or 1.latest
|
|
19
|
+
* [NodeJS](https://nodejs.org/en/) 14.x. We recommend using [nvm](https://github.com/nvm-sh/nvm) to manage NodeJS installations.
|
|
20
|
+
* [Yarn](https://yarnpkg.com/)
|
|
21
|
+
* [TypeScript](https://www.typescriptlang.org/)
|
|
22
|
+
* [Python](https://www.python.org/downloads/) (called as `python3`). For recent versions of MacOS, the system-installed version is fine.
|
|
23
|
+
* [.NET](https://dotnet.microsoft.com/download)
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
### Build & test the boilerplate XYZ provider
|
|
27
|
+
|
|
28
|
+
1. Create a new Github CodeSpaces environment using this repository.
|
|
29
|
+
1. Open a terminal in the CodeSpaces environment.
|
|
30
|
+
1. Run `make build install` to build and install the provider.
|
|
31
|
+
1. Run `make gen_examples` to generate the example programs in `examples/` off of the source `examples/yaml` example program.
|
|
32
|
+
1. Run `make up` to run the example program in `examples/yaml`.
|
|
33
|
+
1. Run `make down` to tear down the example program.
|
|
34
|
+
|
|
35
|
+
### Creating a new provider repository
|
|
36
|
+
|
|
37
|
+
Pulumi offers this repository as a [GitHub template repository](https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-repository-from-a-template) for convenience. From this repository:
|
|
38
|
+
|
|
39
|
+
1. Click "Use this template".
|
|
40
|
+
1. Set the following options:
|
|
41
|
+
* Owner: pulumi
|
|
42
|
+
* Repository name: pulumi-xyz-native (replace "xyz" with the name of your provider)
|
|
43
|
+
* Description: Pulumi provider for xyz
|
|
44
|
+
* Repository type: Public
|
|
45
|
+
1. Clone the generated repository.
|
|
46
|
+
|
|
47
|
+
From the templated repository:
|
|
48
|
+
|
|
49
|
+
1. Search-replace `xyz` with the name of your desired provider.
|
|
50
|
+
|
|
51
|
+
#### Build the provider and install the plugin
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
$ make build install
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
This will:
|
|
58
|
+
|
|
59
|
+
1. Create the SDK codegen binary and place it in a `./bin` folder (gitignored)
|
|
60
|
+
2. Create the provider binary and place it in the `./bin` folder (gitignored)
|
|
61
|
+
3. Generate the dotnet, Go, Node, and Python SDKs and place them in the `./sdk` folder
|
|
62
|
+
4. Install the provider on your machine.
|
|
63
|
+
|
|
64
|
+
#### Test against the example
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
$ cd examples/simple
|
|
68
|
+
$ yarn link @pulumi/xyz
|
|
69
|
+
$ yarn install
|
|
70
|
+
$ pulumi stack init test
|
|
71
|
+
$ pulumi up
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Now that you have completed all of the above steps, you have a working provider that generates a random string for you.
|
|
75
|
+
|
|
76
|
+
#### A brief repository overview
|
|
77
|
+
|
|
78
|
+
You now have:
|
|
79
|
+
|
|
80
|
+
1. A `provider/` folder containing the building and implementation logic
|
|
81
|
+
1. `cmd/pulumi-resource-xyz/main.go` - holds the provider's sample implementation logic.
|
|
82
|
+
2. `deployment-templates` - a set of files to help you around deployment and publication
|
|
83
|
+
3. `sdk` - holds the generated code libraries created by `pulumi-gen-xyz/main.go`
|
|
84
|
+
4. `examples` a folder of Pulumi programs to try locally and/or use in CI.
|
|
85
|
+
5. A `Makefile` and this `README`.
|
|
86
|
+
|
|
87
|
+
#### Additional Details
|
|
88
|
+
|
|
89
|
+
This repository depends on the pulumi-go-provider library. For more details on building providers, please check
|
|
90
|
+
the [Pulumi Go Provider docs](https://github.com/pulumi/pulumi-go-provider).
|
|
91
|
+
|
|
92
|
+
### Build Examples
|
|
93
|
+
|
|
94
|
+
Create an example program using the resources defined in your provider, and place it in the `examples/` folder.
|
|
95
|
+
|
|
96
|
+
You can now repeat the steps for [build, install, and test](#test-against-the-example).
|
|
97
|
+
|
|
98
|
+
## Configuring CI and releases
|
|
99
|
+
|
|
100
|
+
1. Follow the instructions laid out in the [deployment templates](./deployment-templates/README-DEPLOYMENT.md).
|
|
101
|
+
|
|
102
|
+
## References
|
|
103
|
+
|
|
104
|
+
Other resources/examples for implementing providers:
|
|
105
|
+
* [Pulumi Command provider](https://github.com/pulumi/pulumi-command/blob/master/provider/pkg/provider/provider.go)
|
|
106
|
+
* [Pulumi Go Provider repository](https://github.com/pulumi/pulumi-go-provider)
|