Cannot find local directory that definitely exists
dataaxleandy opened this issue · 2 comments
The action is running on a self hosted runner on AWS, and seems to be working until it tries to copy out of the local directory where it cannot find it. Below is the error message. Each "hidden" in it is just from me changing that for security, but the path is correct. Here's a screenshot from the EC2 terminal showing the directory is there: https://lms-data-axle-dpr.d.pr/RWDGf9
Could not chdir to home directory sftpgroup: No such file or directory
SFTP Start
sftp> put -r /usr/bin/actions-runner/_work/apps/apps/backend/projects/hidden/hidden/build-artifact/* data/dev/hidden/hidden
stat /usr/bin/actions-runner/_work/apps/apps/backend/projects/hidden/hidden/build-artifact/*: No such file or directory
Just a quick follow up to this. I changed the workflow file to download the artifact inside the job that uses the SFTP Deploy Action, and it still can't find the directory.
This has been resolved. The job was missing - uses: actions/checkout@v3
as well as having the local path using the entire path string instead of ./
for the root directory.
/usr/bin/actions-runner/_work/apps/apps/backend/projects/hidden/hidden/build-artifact/*
should have been ./backend/projects/hidden/hidden/build-artifact/*
.
Once correcting these two things it began working successfully.