You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your infra code needs to find folder names that do not end in a file name (they end in a folder name)
Your infra code needs to names of files or folders created during the apply (eg in a null resource, or by another provider that creates files)
Your infra code needs to locate other types of files that regular files or folders (eg symbolic links)
Problems:
fileset() does not show folders, only regular files
fileset() evaluates at the beginning of the terraform plan, so it cannot participate in the dependencies graph and occur later in the plan or even in the apply after some files have been created
fileset() does not find other types of files
local_file data source is for reading contents of a file as a string, rather than generating a list of strings
Proposal
Provide a local_filepaths data source with arguments:
path
pattern, default * meaning all matches that start with path, or null for exact match
type would default to file, but could also be folder (or directory if that's better), or * for all types (eventually could be symbolic links, etc)
pattern type (glob or regexp)
The result is a list of objects with attributes relpaths (list of paths relative to path), abspaths (list of absolute paths), and type (actual type resolved).
How much impact is this issue causing?
Medium
Additional Information
No response
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
Terraform CLI and Provider Versions
Latest,
Use Cases or Problem Statement
Use case:
Problems:
local_file
data source is for reading contents of a file as a string, rather than generating a list of stringsProposal
Provide a
local_filepaths
data source with arguments:path
pattern
, default*
meaning all matches that start withpath
, or null for exact matchtype
would default tofile
, but could also befolder
(ordirectory
if that's better), or*
for all types (eventually could be symbolic links, etc)The result is a list of objects with attributes
relpaths
(list of paths relative topath
),abspaths
(list of absolute paths), andtype
(actual type resolved).How much impact is this issue causing?
Medium
Additional Information
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: