Method: RubyTerraform::ClassMethods#state_push
- Defined in:
- lib/ruby_terraform.rb
#state_push(parameters = {}, invocation_options = {}) ⇒ Object
Invokes the terraform state push command which updates remote state from a local state file.
This command “pushes” a local state and overwrites remote state with a local state file. The command will protect you against writing an older serial or a different state file lineage unless you pass true for the :force option.
This command works with local state (it will overwrite the local state), but is less useful for this use case.
If :path is “-”, then this command will read the state to push from stdin. Data from stdin is not streamed to the backend: it is loaded completely (until pipe close), verified, and then pushed.
1125 1126 1127 1128 |
# File 'lib/ruby_terraform.rb', line 1125 def state_push(parameters = {}, = {}) exec(RubyTerraform::Commands::StatePush, parameters, ) end |