Skip to content

Can't use environment variable for target #28

@Pikachews

Description

@Pikachews

This does not seem to work:

    - name: Upload
      uses: appleboy/scp-action@v0.1.1
      with:
        host: $HOST
        username: $USERNAME
        key: ${{ secrets.STAGING_MAIN_KEY }}
        source: ${{ github.sha }}.zip
        target: $TARGET_PATH        # <---- using environment variable

(I have my env vars defined at the top-level.)

It prints the following output:

tar all files into /tmp/941631237/O7WrNb0QY9.tar
scp file to server.
create folder $TARGET_PATH
drone-scp error:  Process exited with status 1
drone-scp rollback: remove all target tmp file
remove file O7WrNb0QY9.tar
2020/06/24 06:46:37 Process exited with status 1

It says literally $TARGET_PATH in there, instead of the value of $TARGET_PATH.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions