First tar and gzip your folder on the server in the ssh session, the syntax is:
rhc ssh <app_name> tar czf <name_of_new_file>.tar.gz <name_of_directory>
Secondly, after you disconnected from the openshift server (with CTRL-D ), upload this file to the local system:
rhc scp <app_name> download <local_destination> <absolute_path_to_remote_file>
Then, on your local computer, you can extract the file and perform your actions.
source share