Coder Social home page Coder Social logo

woodpecker-scp's Introduction

woodpecker-scp

status-badge

woodpecker-scp is a small plugin for weoodpecker, which allows users to upload diretories and files to any server that supports scp.

Usage

To use woodpecker-scp use the following entries in your .woodpecker.yml:

publish:
    image: git.merp.digital/eranmorkon/woodpecker-scp:1.1.0
    settings:
        ssh_key:
            from_secret: ssh_key
        ssh_known_hosts:
            from_secret: ssh_known_hosts
        extra_flags: -r
        source: local-path
        destination: "user@server:remote-path"

The plugin is published in the git.merp.digital oci registry, the latest tag is always the latest release, addidtionally release tags in the format x.y.z point to the specified releases. The develop tag always holds the latest commit to the develop branch and can therefore be seen as nighty, it is definitely not stable however.

Settings

ssh_key

The SSH key holds the private key scp will use to connect to the server, I would recommend to generate a new private/public key pair for your CI job and add the contents of your private key file as secret. The add the public key to the server's ~/.ssh/authorized_keys file as usual.

ssh_known_hosts

This should be the content of the ~/.ssh/known_hosts file. This is used to let scp verify the identity of the remote server. If you skip this step the transfer will not work, as scp can not verify that the server you are connecting to is actually the server you want to connect to. You can disable this behaviour using extra_flags but I highly recommend to not do that, and instead add the known_hosts entry.

extra_flags

This setting is used to add extra flags to the scp command. Per default scp will be executed with the -Bv flags, for batch mode and verbose so you can see some output from scp in the CI log. You can add any flag that scp supports, for example -r for a recursive copy.

source

The source directory scp will copy the data from, this can be in the CI container, or on a remote server, however the later one is untested at the moment.

destination

The destination directory scp will copy the data to, this can be on a remote server, or in the CI container, however the later one is untested at the moment.

License

Licensed under the MIT license.

SPDX-License-Identifier: MIT

woodpecker-scp's People

Contributors

zenermerps avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.