A formae plugin for managing files on SFTP servers. This plugin was created as part of the Plugin SDK Tutorial.
| Resource Type | Description |
|---|---|
SFTP::Files::File |
Manages files on an SFTP server |
Configure a target in your forma file:
import "@sftp/sftp.pkl"
new formae.Target {
label = "sftp-server"
config = new sftp.Config {
url = "sftp://hostname:22"
}
}The plugin reads SFTP credentials from environment variables:
| Variable | Description |
|---|---|
SFTP_USERNAME |
SFTP username |
SFTP_PASSWORD |
SFTP password |
Set these environment variables before starting the formae agent.
See the examples/ directory for usage examples.
import "@sftp/sftp.pkl"
new sftp.File {
label = "hello"
path = "/upload/hello.txt"
content = "Hello from formae!"
permissions = "0644"
}# Apply resources
formae apply --mode reconcile examples/basic/main.pklThis plugin is licensed under FSL-1.1-ALv2.