code: def _push_local_dir(self):
      remote_upload_to = self._generate_tmp_cloud_storage_path()
      # pack local dir
      _, local_path = tempfile.mkstemp()
      shutil.make_archive(local_path, "gztar", os.getcwd())
      # local source -> s3
      self._run_with_retry(
          lambda: self.s3_client.upload_file(
              Filename=local_path + ".tar.gz",
              Bucket=self.bucket,
              Key=remote_upload_to,
          )
      )
      # remove local archive
      os.unlink(local_path)
  
      bucket_address = f"s3://{self.bucket}/{remote_upload_to}"
      # s3 -> remote target
      retcode, _ = self.job_manager.run_and_wait(
          f"pip install -q awscli && "
          f"aws s3 cp {bucket_address} archive.tar.gz && "
          f"tar xf archive.tar.gz ",
          {},
      )
      if retcode != 0:
          raise FileUploadError(
              f"Error uploading local dir to session "
              f"{self.cluster_manager.cluster_name}."
          )
      try:
          self._run_with_retry(
              lambda: self.s3_client.delete_object(
                  Bucket=self.bucket, Key=remote_upload_to
              ),
              initial_retry_delay_s=2,
          )
      except RuntimeError as e:
          logger.warning(f"Could not remove temporary S3 object: {e}")
  
imports: import os
  import shutil
  import sys
  import tempfile
  from typing import Optional
  import boto3
  from google.cloud import storage
  from ray_release.aws import RELEASE_AWS_BUCKET
  from ray_release.cluster_manager.cluster_manager import ClusterManager
  from ray_release.exception import FileDownloadError, FileUploadError
  from ray_release.file_manager.file_manager import FileManager
  from ray_release.job_manager import JobManager
  from ray_release.logger import logger
  from ray_release.util import exponential_backoff_retry, generate_tmp_cloud_storage_path, S3_CLOUD_STORAGE, GS_CLOUD_STORAGE, GS_BUCKET
label_desc: Use image node_id 6 for calling the JobFileManager obj's underlying member method code with example usage: obj._push_local_dir() without return types