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

Extract files from artifacts folder dist/**

Alberto Torrisi
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 15, 2021

Hello guys, I have a question and I hope someone can help me!

I have this pipeline:

#bitbucket-pipelines.yml
image: node:latest

pipelines:
  default:
    - step:
        name: Build VUE Project
        caches:
            - node
        script:
            - yarn install
            - yarn run build
        artifacts:
          - dist/**
    - step:
        name: Deploy to CPANEL
        deployment: production
        script:
          - pipe: (....something)
            variables:
              USER: $ftp_user
              PASSWORD: $ftp_password
              SERVER: $ftp_host
              REMOTE_PATH: $ftp_remote_path

It works and when pipeline is completed in my server prod i found my folder dist with my app.

But I would only files inside the folder dist.

I imagine to have in my root folder server production all files inside dist and not the folder dist(with all files inside).

Someone have some suggestions? Thank you 

2 answers

1 accepted

0 votes
Answer accepted
Alberto Torrisi
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 15, 2021

For everyone will have same problem the solution is to add this line inside step:

LOCAL_PATH: 'dist' 

So, only the content of the directory dist will be deployed! Have a nice coding day :)

brycer169
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 11, 2022

I'm trying to do this same thing, but can you just clarify where you put LOCAL_PATH? was it under the artifacts section? I'm trying variations but haven't found one that works just yet...

0 votes
Ribik Khoteja
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 1, 2022

It didn't worked for me. Everytime I run pipeline dist folder is also created in Cpanel. I have added LOCAL_PATH: 'dist' under REMOTE_PATH.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events