Comments (2)
Hi @cveld 👋
Sorry you ran into trouble here.
The issue you describe is analogous to that documented in Import string always forces replacement. This is a consequence of the implementation of the ImportState()
method on the random_string
resource, which explicitly sets the special
attribute to true
during the import:
func (r *stringResource) ImportState(ctx context.Context, req resource.ImportStateRequest, resp *resource.ImportStateResponse) {
id := req.ID
state := stringModelV3{
ID: types.StringValue(id),
Result: types.StringValue(id),
Length: types.Int64Value(int64(len(id))),
Special: types.BoolValue(true),
/* ... */
Unfortunately, at this time, with the configuration you have supplied, the only options are those laid out in https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/string#avoiding-replacement.
In order to better handle situations such as the one you have encountered we need to implement Import with Configuration. Please feel free to up-vote this issue to signal your interest.
As there is nothing further that can currently be done for the issue that you raised I am going to close this issue.
References:
from terraform-provider-random.
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
from terraform-provider-random.
Related Issues (20)
- Documentation: random_shuffle output is already list HOT 2
- random_pet generating non unique names
- Update Go Module to Go 1.20 Minimum HOT 1
- tyring to upgrade azurerm version but getting below error. HOT 3
- Ambiguous wording in docs on the parameters for RandomPassword, eg "numeric = true" can still generate a password without numerics.
- Resource 'snowflake_grant_privileges_to_role' marks 'priveleges' attribute as changed regardless of any changes being made HOT 2
- random_shuffle need to add position 0 of an array to return 1 single result string HOT 2
- Support UUIDv7
- Enable password cannot have more than 2 repeated characters
- Feature Request: random IP from CIDR range HOT 4
- Feature Request: Random Date HOT 2
- `random_bytes` resource does not explicitly mention being "sufficiently random for cryptographic use HOT 2
- `random_bytes` resource does not explicitly mention being "sufficiently random for cryptographic use" HOT 2
- Improve documentation HOT 2
- Adjust Go Module Address
- Panic on `random_string` when all properties set to `false` HOT 3
- Importing a random password using an import block outputs a sensitive value during apply. HOT 1
- `provider::random::string()` function HOT 2
- Add word/profanity filter for random_pet HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from terraform-provider-random.