Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

No such file or directory for Working Local Directory

jhorning-tyler March 26, 2019

This is the output I get when I try to run my first pipeline:

2s
+ docker container run \   --volume=/opt/atlassian/pipelines/agent/build:/opt/atlassian/pipelines/agent/build \   --volume=/opt/atlassian/pipelines/agent/ssh:/opt/atlassian/pipelines/agent/ssh:ro \   --volume=/usr/local/bin/docker:/usr/local/bin/docker:ro \   --workdir=$(pwd) \   --label=org.bitbucket.pipelines.system=true \   --env=CI="$CI" \   --env=BITBUCKET_COMMIT="$BITBUCKET_COMMIT" \   --env=BITBUCKET_BUILD_NUMBER="$BITBUCKET_BUILD_NUMBER" \   --env=BITBUCKET_BRANCH="$BITBUCKET_BRANCH" \   --env=BITBUCKET_PR_DESTINATION_BRANCH="$BITBUCKET_PR_DESTINATION_BRANCH" \   --env=BITBUCKET_PR_DESTINATION_COMMIT="$BITBUCKET_PR_DESTINATION_COMMIT" \   --env=BITBUCKET_PR_ID="$BITBUCKET_PR_ID" \   --env=BITBUCKET_TAG="$BITBUCKET_TAG" \   --env=BITBUCKET_BOOKMARK="$BITBUCKET_BOOKMARK" \   --env=BITBUCKET_REPO_OWNER="$BITBUCKET_REPO_OWNER" \   --env=BITBUCKET_REPO_OWNER_UUID="$BITBUCKET_REPO_OWNER_UUID" \   --env=BITBUCKET_REPO_SLUG="$BITBUCKET_REPO_SLUG" \   --env=BITBUCKET_REPO_UUID="$BITBUCKET_REPO_UUID" \   --env=BITBUCKET_CLONE_DIR="$BITBUCKET_CLONE_DIR" \   --env=BITBUCKET_PARALLEL_STEP="$BITBUCKET_PARALLEL_STEP" \   --env=BITBUCKET_PARALLEL_STEP_COUNT="$BITBUCKET_PARALLEL_STEP_COUNT" \   --env=BITBUCKET_GIT_HTTP_ORIGIN="$BITBUCKET_GIT_HTTP_ORIGIN" \   --env=BITBUCKET_GIT_SSH_ORIGIN="$BITBUCKET_GIT_SSH_ORIGIN" \   --env=PIPELINES_JWT_TOKEN="$PIPELINES_JWT_TOKEN" \   --env=BITBUCKET_DOCKER_HOST_INTERNAL="$BITBUCKET_DOCKER_HOST_INTERNAL" \   --env=DOCKER_HOST="tcp://host.docker.internal:2375" \   --env=LOCAL_PATH="/Users/jhorning/Sites/dev.jtcc.edu/" \   --env=REMOTE_PATH="/var/www/html/jtc/" \   --env=SERVER="164.106.55.220" \   --env=USER="webuser2" \   --add-host="host.docker.internal:$BITBUCKET_DOCKER_HOST_INTERNAL" \   bitbucketpipelines/sftp-deploy:0.3.1Unable to find image 'bitbucketpipelines/sftp-deploy:0.3.1' locally0.3.1: Pulling from bitbucketpipelines/sftp-deploy169185f82c45: Pulling fs layer2f7012b9f715: Pulling fs layera0d7c4d4e654: Pulling fs layera0d7c4d4e654: Verifying Checksuma0d7c4d4e654: Download complete169185f82c45: Verifying Checksum169185f82c45: Download complete2f7012b9f715: Verifying Checksum2f7012b9f715: Download complete169185f82c45: Pull complete2f7012b9f715: Pull completea0d7c4d4e654: Pull completeDigest: sha256:fb8c4dee7f83202b2824e918a329c270a095a9993c2ccd57af561bbf6e10b8cbStatus: Downloaded newer image for bitbucketpipelines/sftp-deploy:0.3.1INFO: Starting SFTP deployment to 164.106.55.220:/var/www/html/jtc/...stat /Users/jhorning/Sites/dev.jtcc.edu/: No such file or directorysftp> mput /Users/jhorning/Sites/dev.jtcc.edu/✖ Deployment failed.

I'm not sure why it says there's no such file or directory since the dev.jtcc.edu folder is the local folder I have setup in Sourcetree and am able to push and pull from it? Any help would be greatly appreciated!

1 answer

1 accepted

0 votes
Answer accepted
mwatson
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 31, 2019

You have set

LOCAL_PATH:"/Users/jhorning/Sites/dev.jtcc.edu/"

 When it should probably just be 

LOCAL_PATH: "dev.jtcc.edu"

(i.e. the path relative to your checkout that you want to ftp).

There is no /Users/jhorning/Sites/dev.jtcc.edu/ in the build when your Pipeline runs.

jhorning-tyler April 1, 2019

Hi Matthew,

I apologize, I forgot I posted this before submitting a help ticket. I was told that it should be:

LOCAL_PATH: 'build'

but for some reason, I have to put the full path to get it to work:

LOCAL_PATH: '/opt/atlassian/pipelines/agent/build'

 

Please close this post and/or remove it. Thank you for your help!

mattw_watson May 5, 2019

'build' would be the directory the build is running in. You just need to have LOCAL_PATH:'.' too get all the files in the repo

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events