Sha256: 5fbd42cc7f77627e69efe190bf95c1d6d9a49f940f47d4071c4abf17bccafd0b

Contents?: true

Size: 1.21 KB

Versions: 104

Compression:

Stored size: 1.21 KB

Contents

module Eco
  module API
    class Session
      class Config
        class SFTP < BaseConfig

          def configured?
            required = host && user && key_file
            !!required
          end

          def host=(value)
            self["host"] = value
          end

          def host
            self["host"]
          end

          def user=(value)
            self["user"] = value
          end

          def user
            self["user"]
          end

          def key_file=(key)
            self["key_file"] = key
          end

          def key_file
            self["key_file"]
          end

          def base_path=(path)
            self["base_path"] = path
          end

          def base_path
            self["base_path"]
          end

          def enviro_subpaths=(hash)
            self["enviro_subpaths"] = hash
          end

          def enviro_subpaths
            self["enviro_subpaths"]
          end

          def enviro_subpath
            enviro_subpaths[config.active_enviro]
          end

          def remote_folder
            base_path + "/" + enviro_subpath
          end

        end
      end
    end
  end
end

Version data entries

104 entries across 104 versions & 1 rubygems

Version Path
eco-helpers-2.0.61 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.60 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.59 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.58 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.57 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.56 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.55 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.54 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.53 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.52 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.51 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.50 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.49 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.48 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.47 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.46 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.45 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.44 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.43 lib/eco/api/session/config/sftp.rb
eco-helpers-2.0.42 lib/eco/api/session/config/sftp.rb