Importing Files for a Specific CloudApps Site
- Put your site's files (normally sourced from <docroot>/sites/default/files) in a folder somewhere on your PC that you know how to find in the console. The content of your files directory should be the ONLY thing in the folder!
- Open a terminal/bash window.
- Navigate to the folder where you put your files.
- Find your project in the CloudApps overview. Click on the circle for the code row for your project. This should be named something like ccat-prod.
- Take note of the pod name in the top left.
- In your terminal, ensure you are logged into CloudApps (oc login) and on the right project.
- Use the rsync tool to sync your files. The command will look like "oc rsync . <pod>:/opt/app-root/src/sites/default/files". For example, to put the files in the sites/default/files folder for the ccat site, the command would be: "oc rsync . ccat-prod-17-djmww:/opt/app-root/src/sites/default/files". Note that the pod name will change if the pod goes down - always check you are using the right pod.
- If you need to place files into a specific directory then the command above would look like this: "oc rsync . efc-prod-205-xmj8w:/opt/app-root/src/sites/default/files/AZRateSheets " or "oc rsync . <pod>:/opt/app-root/src/sites/default/files/<specific-directory>"
- Once the rsync finishes, the files directory will be ready to use.