File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 3939)
4040
4141def calculate_list_of_files_to_move (** context ):
42- sftp_conn = SFTPHook (ftp_conn_id = ALMA_SFTP_CONNECTION_ID )
42+ sftp_conn = SFTPHook (ssh_conn_id = ALMA_SFTP_CONNECTION_ID )
4343 files_list = sftp_conn .list_directory ("./" )
4444 # Ignore an file that does not start with this prefix
4545 files = [f for f in files_list if f .startswith ("alma_bibs__boundwith2_20" )]
@@ -69,7 +69,7 @@ def calculate_list_of_files_to_move(**context):
6969
7070def archive_files_in_sftp (** context ):
7171 """Move sftp files into the archive folder"""
72- sftp_conn = SFTPHook (ftp_conn_id = ALMA_SFTP_CONNECTION_ID )
72+ sftp_conn = SFTPHook (ssh_conn_id = ALMA_SFTP_CONNECTION_ID )
7373 # Paramiko is the underlying package used for SSH/SFTP conns
7474 # the paramiko client exposes a lot more core SFTP functionality
7575 paramiko_conn = sftp_conn .get_conn ()
Original file line number Diff line number Diff line change 3939)
4040
4141def calculate_list_of_files_to_move (** context ):
42- sftp_conn = SFTPHook (ftp_conn_id = ALMA_SFTP_CONNECTION_ID )
42+ sftp_conn = SFTPHook (ssh_conn_id = ALMA_SFTP_CONNECTION_ID )
4343 files_list = sftp_conn .list_directory ("./" )
4444 # Ignore an file that does not start with this prefix
4545 just_alma_bibs_files = [f for f in files_list if f .startswith ("alma_bibs__20" )]
@@ -70,7 +70,7 @@ def calculate_list_of_files_to_move(**context):
7070
7171def archive_files_in_sftp (** context ):
7272 """Move sftp files into the archive folder"""
73- sftp_conn = SFTPHook (ftp_conn_id = ALMA_SFTP_CONNECTION_ID )
73+ sftp_conn = SFTPHook (ssh_conn_id = ALMA_SFTP_CONNECTION_ID )
7474 # Paramiko is the underlying package used for SSH/SFTP conns
7575 # the paramiko client exposes a lot more core SFTP functionality
7676 paramiko_conn = sftp_conn .get_conn ()
You can’t perform that action at this time.
0 commit comments