Skip to content
Snippets Groups Projects
Commit 4201c612 authored by Bob Mottram's avatar Bob Mottram
Browse files

Ability to change privacy status of synced peertube videos

parent 18a0866d
No related branches found
No related tags found
No related merge requests found
......@@ -82,6 +82,14 @@ function peertube_import_from_syncthing {
echo " peertubensfw='--nsfw'";
echo 'fi';
echo '';
echo "peertubeprivate='-P 3'";
echo "if grep 'public' \"\$search_dir/login\"; then";
echo " peertubeprivate='-P 1'";
echo 'fi';
echo "if grep 'Public' \"\$search_dir/login\"; then";
echo " peertubeprivate='-P 1'";
echo 'fi';
echo '';
echo 'failed_uploads=0';
echo '';
echo "for video_file in \$search_dir/*; do";
......@@ -92,7 +100,7 @@ function peertube_import_from_syncthing {
echo " if ! grep \"\$video_file\" /root/.peertube_uploaded; then";
echo " if ! grep \"\$video_file\" /root/.peertube_uploading; then";
echo " echo \"\$video_file\" >> /root/.peertube_uploading";
echo " if node \$import_script \$peertubensfw -u \"\$peertubedomain\" -U \"\$peertubeuser\" --password \"\$peertubepassword\" -f \"\$video_file\"; then";
echo " if node \$import_script \$peertubensfw \$peertubeprivate -u \"\$peertubedomain\" -U \"\$peertubeuser\" --password \"\$peertubepassword\" -f \"\$video_file\"; then";
echo " echo \"\$video_file\" >> /root/.peertube_uploaded";
echo " sed -i \"/\$video_file/d\" /root/.peertube_uploading";
echo " exit 0";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment