generated from pulumi/pulumi-tf-provider-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 1
/
getDatabaseSoftwareImage.go
230 lines (197 loc) · 11.6 KB
/
getDatabaseSoftwareImage.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package database
import (
"context"
"reflect"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// This data source provides details about a specific Database Software Image resource in Oracle Cloud Infrastructure Database service.
//
// Gets information about the specified database software image.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-oci/sdk/go/oci/Database"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := Database.GetDatabaseSoftwareImage(ctx, &database.GetDatabaseSoftwareImageArgs{
// DatabaseSoftwareImageId: oci_database_database_software_image.Test_database_software_image.Id,
// }, nil)
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
func LookupDatabaseSoftwareImage(ctx *pulumi.Context, args *LookupDatabaseSoftwareImageArgs, opts ...pulumi.InvokeOption) (*LookupDatabaseSoftwareImageResult, error) {
var rv LookupDatabaseSoftwareImageResult
err := ctx.Invoke("oci:Database/getDatabaseSoftwareImage:getDatabaseSoftwareImage", args, &rv, opts...)
if err != nil {
return nil, err
}
return &rv, nil
}
// A collection of arguments for invoking getDatabaseSoftwareImage.
type LookupDatabaseSoftwareImageArgs struct {
// The DB system [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm).
DatabaseSoftwareImageId string `pulumi:"databaseSoftwareImageId"`
}
// A collection of values returned by getDatabaseSoftwareImage.
type LookupDatabaseSoftwareImageResult struct {
// The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment.
CompartmentId string `pulumi:"compartmentId"`
DatabaseSoftwareImageId string `pulumi:"databaseSoftwareImageId"`
// List of one-off patches for Database Homes.
DatabaseSoftwareImageIncludedPatches []string `pulumi:"databaseSoftwareImageIncludedPatches"`
// List of one-off patches for Database Homes.
DatabaseSoftwareImageOneOffPatches []string `pulumi:"databaseSoftwareImageOneOffPatches"`
// The database version with which the database software image is to be built.
DatabaseVersion string `pulumi:"databaseVersion"`
// Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).
DefinedTags map[string]interface{} `pulumi:"definedTags"`
// The user-friendly name for the database software image. The name does not have to be unique.
DisplayName string `pulumi:"displayName"`
// Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Department": "Finance"}`
FreeformTags map[string]interface{} `pulumi:"freeformTags"`
// The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the database software image.
Id string `pulumi:"id"`
// To what shape the image is meant for.
ImageShapeFamily string `pulumi:"imageShapeFamily"`
// The type of software image. Can be grid or database.
ImageType string `pulumi:"imageType"`
// The patches included in the image and the version of the image.
IncludedPatchesSummary string `pulumi:"includedPatchesSummary"`
// True if this Database software image is supported for Upgrade.
IsUpgradeSupported bool `pulumi:"isUpgradeSupported"`
// Detailed message for the lifecycle state.
LifecycleDetails string `pulumi:"lifecycleDetails"`
// The output from the OPatch lsInventory command, which is passed as a string.
LsInventory string `pulumi:"lsInventory"`
// The PSU or PBP or Release Updates. To get a list of supported versions, use the [ListDbVersions](https://docs.cloud.oracle.com/iaas/api/#/en/database/latest/DbVersionSummary/ListDbVersions) operation.
PatchSet string `pulumi:"patchSet"`
SourceDbHomeId string `pulumi:"sourceDbHomeId"`
// The current state of the database software image.
State string `pulumi:"state"`
// The date and time the database software image was created.
TimeCreated string `pulumi:"timeCreated"`
}
func LookupDatabaseSoftwareImageOutput(ctx *pulumi.Context, args LookupDatabaseSoftwareImageOutputArgs, opts ...pulumi.InvokeOption) LookupDatabaseSoftwareImageResultOutput {
return pulumi.ToOutputWithContext(context.Background(), args).
ApplyT(func(v interface{}) (LookupDatabaseSoftwareImageResult, error) {
args := v.(LookupDatabaseSoftwareImageArgs)
r, err := LookupDatabaseSoftwareImage(ctx, &args, opts...)
var s LookupDatabaseSoftwareImageResult
if r != nil {
s = *r
}
return s, err
}).(LookupDatabaseSoftwareImageResultOutput)
}
// A collection of arguments for invoking getDatabaseSoftwareImage.
type LookupDatabaseSoftwareImageOutputArgs struct {
// The DB system [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm).
DatabaseSoftwareImageId pulumi.StringInput `pulumi:"databaseSoftwareImageId"`
}
func (LookupDatabaseSoftwareImageOutputArgs) ElementType() reflect.Type {
return reflect.TypeOf((*LookupDatabaseSoftwareImageArgs)(nil)).Elem()
}
// A collection of values returned by getDatabaseSoftwareImage.
type LookupDatabaseSoftwareImageResultOutput struct{ *pulumi.OutputState }
func (LookupDatabaseSoftwareImageResultOutput) ElementType() reflect.Type {
return reflect.TypeOf((*LookupDatabaseSoftwareImageResult)(nil)).Elem()
}
func (o LookupDatabaseSoftwareImageResultOutput) ToLookupDatabaseSoftwareImageResultOutput() LookupDatabaseSoftwareImageResultOutput {
return o
}
func (o LookupDatabaseSoftwareImageResultOutput) ToLookupDatabaseSoftwareImageResultOutputWithContext(ctx context.Context) LookupDatabaseSoftwareImageResultOutput {
return o
}
// The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment.
func (o LookupDatabaseSoftwareImageResultOutput) CompartmentId() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.CompartmentId }).(pulumi.StringOutput)
}
func (o LookupDatabaseSoftwareImageResultOutput) DatabaseSoftwareImageId() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.DatabaseSoftwareImageId }).(pulumi.StringOutput)
}
// List of one-off patches for Database Homes.
func (o LookupDatabaseSoftwareImageResultOutput) DatabaseSoftwareImageIncludedPatches() pulumi.StringArrayOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) []string { return v.DatabaseSoftwareImageIncludedPatches }).(pulumi.StringArrayOutput)
}
// List of one-off patches for Database Homes.
func (o LookupDatabaseSoftwareImageResultOutput) DatabaseSoftwareImageOneOffPatches() pulumi.StringArrayOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) []string { return v.DatabaseSoftwareImageOneOffPatches }).(pulumi.StringArrayOutput)
}
// The database version with which the database software image is to be built.
func (o LookupDatabaseSoftwareImageResultOutput) DatabaseVersion() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.DatabaseVersion }).(pulumi.StringOutput)
}
// Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).
func (o LookupDatabaseSoftwareImageResultOutput) DefinedTags() pulumi.MapOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) map[string]interface{} { return v.DefinedTags }).(pulumi.MapOutput)
}
// The user-friendly name for the database software image. The name does not have to be unique.
func (o LookupDatabaseSoftwareImageResultOutput) DisplayName() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.DisplayName }).(pulumi.StringOutput)
}
// Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Department": "Finance"}`
func (o LookupDatabaseSoftwareImageResultOutput) FreeformTags() pulumi.MapOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) map[string]interface{} { return v.FreeformTags }).(pulumi.MapOutput)
}
// The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the database software image.
func (o LookupDatabaseSoftwareImageResultOutput) Id() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.Id }).(pulumi.StringOutput)
}
// To what shape the image is meant for.
func (o LookupDatabaseSoftwareImageResultOutput) ImageShapeFamily() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.ImageShapeFamily }).(pulumi.StringOutput)
}
// The type of software image. Can be grid or database.
func (o LookupDatabaseSoftwareImageResultOutput) ImageType() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.ImageType }).(pulumi.StringOutput)
}
// The patches included in the image and the version of the image.
func (o LookupDatabaseSoftwareImageResultOutput) IncludedPatchesSummary() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.IncludedPatchesSummary }).(pulumi.StringOutput)
}
// True if this Database software image is supported for Upgrade.
func (o LookupDatabaseSoftwareImageResultOutput) IsUpgradeSupported() pulumi.BoolOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) bool { return v.IsUpgradeSupported }).(pulumi.BoolOutput)
}
// Detailed message for the lifecycle state.
func (o LookupDatabaseSoftwareImageResultOutput) LifecycleDetails() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.LifecycleDetails }).(pulumi.StringOutput)
}
// The output from the OPatch lsInventory command, which is passed as a string.
func (o LookupDatabaseSoftwareImageResultOutput) LsInventory() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.LsInventory }).(pulumi.StringOutput)
}
// The PSU or PBP or Release Updates. To get a list of supported versions, use the [ListDbVersions](https://docs.cloud.oracle.com/iaas/api/#/en/database/latest/DbVersionSummary/ListDbVersions) operation.
func (o LookupDatabaseSoftwareImageResultOutput) PatchSet() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.PatchSet }).(pulumi.StringOutput)
}
func (o LookupDatabaseSoftwareImageResultOutput) SourceDbHomeId() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.SourceDbHomeId }).(pulumi.StringOutput)
}
// The current state of the database software image.
func (o LookupDatabaseSoftwareImageResultOutput) State() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.State }).(pulumi.StringOutput)
}
// The date and time the database software image was created.
func (o LookupDatabaseSoftwareImageResultOutput) TimeCreated() pulumi.StringOutput {
return o.ApplyT(func(v LookupDatabaseSoftwareImageResult) string { return v.TimeCreated }).(pulumi.StringOutput)
}
func init() {
pulumi.RegisterOutputType(LookupDatabaseSoftwareImageResultOutput{})
}