Skip to content

Commit

Permalink
enhancement(sftp): Add spool volume and README
Browse files Browse the repository at this point in the history
  • Loading branch information
Stell0 committed Feb 21, 2025
1 parent 17dcff2 commit c2eb82f
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
1 change: 1 addition & 0 deletions imageroot/systemd/user/sftp.service
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ ExecStart=/usr/bin/podman run --conmon-pidfile %t/sftp.pid \
--name=%N \
--volume=moh:/var/sftp/moh:z \
--volume=sounds:/var/sftp/sounds:z \
--volume=spool:/var/sftp/spool:z \
--volume=sftp_ssh_config:/etc/ssh:Z \
--env=ASTERISK_RECORDING_SFTP_PORT \
--env=AMPMGRUSER \
Expand Down
22 changes: 22 additions & 0 deletions sftp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,25 @@ On NethVoice, systemd unit file is provided. To enable it automatically, launch
- `AMPDBNAME` FreePBX MariaDB database name (default: asterisk)
- `NETHVOICE_MARIADB_PORT` Port of MariaDB
- `ASTERISK_RECORDING_SFTP_PORT` Port where sftp service will be reachable

## Access volumes

Shared volumes are:

- `sounds` - All asterisk system sounds, recordings and announcements
- `moh` - Hold music
- `spool` - All Asterisk spool directories (with call recordings under `spool/monitor`)

To access sftp server, connect using sftp on port `$ASTERISK_RECORDING_SFTP_PORT` using the user `asterisk` and the NethVoice admin password.
By default sftp access is only enabled from the same machine, to access from the outside, you have to open the port on firewall:

example: ASTERISK_RECORDING_SFTP_PORT=20033, nethvoice instace is 1
```
firewall-cmd --permanent --service=nethvoice1 --add-port=20033/tcp
firewall-cmd --reload
```

sample scp command:
```
scp -r -P 20033 asterisk@HOST:spool/monitor ./
```

0 comments on commit c2eb82f

Please sign in to comment.