Set config variable for SFTP_TO_GO server

This commit is contained in:
rebuilt 2023-03-20 13:05:43 -07:00
parent e41a90bd9c
commit db3e4f1178

View file

@ -4,7 +4,7 @@ require 'uri'
module Sftp
class Directory
def self.open(path: '/data/survey_responses/clean', &block)
sftptogo_url = ENV['SFTPTOGO_URL']
sftptogo_url = ENV['ECP_SFTPTOGO_URL']
uri = URI.parse(sftptogo_url)
Net::SFTP.start(uri.host, uri.user, password: uri.password) do |sftp|
sftp.dir.foreach(path) do |entry|