Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: deprecate ssh_skip_request_pty #222

Merged
merged 1 commit into from
Jul 29, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions builder/vmware/common/ssh_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,23 @@
package common

import (
"log"

"github.com/hashicorp/packer-plugin-sdk/communicator"
"github.com/hashicorp/packer-plugin-sdk/template/interpolate"
)

type SSHConfig struct {
Comm communicator.Config `mapstructure:",squash"`

// These are deprecated, but we keep them around for BC
// TODO(@mitchellh): remove
// TODO: Deprecated. Remove in next major release
SSHSkipRequestPty bool `mapstructure:"ssh_skip_request_pty"`
}

func (c *SSHConfig) Prepare(ctx *interpolate.Context) []error {
if c.SSHSkipRequestPty {
c.Comm.SSHPty = false
tenthirtyam marked this conversation as resolved.
Show resolved Hide resolved
log.Printf("[WARN] 'ssh_skip_request_pty' is deprecated and will be removed in the next major release.")
}

return c.Comm.Prepare(ctx)
Expand Down