Runway configuration ‘path’ settings.
Path(module, env_root, cache_dir=None, git_source_class=<class 'runway.sources.git.Git'>)¶
Path is responsible for parsing the
pathproperty of a Runway configuration. It then can determine if the path specified is locally sourced or remotely sourced through a service such as `Git`_ or S3.
pathvariables are defined relative to the root project folder. The value for this cannot be higher than the Runway config file, it must be at the runway file itself or in a sub directory.
deployments: - modules: - path: my/local/module.cfn - my/local/module.cfn # same as above - ./ # module is in the root
pathis remote, Runway is responsible for fetching the resource and returning the location of it’s cached path. The information for retrieving those sources can be controlled via runway rather than manually retrieving each one.
deployments: - modules: - path: git::git://github.com/your_handle/your_repo.git//my-module.cfn
pathstructure is based on the encoding found in Terraform modules.
The values parsed from the string are as follows:
Determine if the source is local or remote. The initial prefix is used to determine this separated by :: in the string. A path is considered local if it contains no source type value.
deployments: - modules: # source is `git` - path: git::git://github.com/foo/bar.git
The uniform resource identifier when targetting a remote resource. This instructs runway on where to retrieve your module.
deployments: - modules: # uri is `git://github.com/foo/bar.git` - path: git::git://github.com/foo/bar.git
The relative location of the module files from the root directory. This value is specified as a path after the uri separated by //
deployments: - modules: # location is `my/path` - path: git::git://github.com/foo/bar.git//my/path
The remaining options that are passed along to the Source. This is specified in the path following the ? separator. Multiple option keys and values can be specified with the & as the separator. Each remote source can have different options for retrieval, please make sure to review individual source types to get more information on properly formatting.
deployments: - modules: # options are `foo=bar&ba=bop` - path: git::git://github.com/foo/bar.git//my/path?foo=bar&baz=bop
- Keyword Arguments
env_root (str) – The current environments root directory path string.
cache_dir (Optional[str]) – When a remote resource is requested it’s Source object requires a cache directory to store it’s request. This allows for an override of that default directory.
git_source_class (Optional[Git]) – Dependency injection for the Git type Source.
Transform object into configuration settings for remote Sources.
Retrieve the relevant elements of the path variable passed.
Given a dictionary with a path parameter parse the value into it’s specific components. The path structure is based on the encoding found in Terraform modules.