[Git][ftp-team/dak][master] 2 commits: link_morgue.sh: also transfer files older than 14 days

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[Git][ftp-team/dak][master] 2 commits: link_morgue.sh: also transfer files older than 14 days

Ansgar Burchardt-8
GitLab

Ansgar pushed to branch master at Debian FTP Team / dak

Commits:

  • df16387a
    by Ansgar Burchardt at 2019-06-25T21:13:58Z
    link_morgue.sh: also transfer files older than 14 days
    
    find's `-ctime 14` option only matches files that were changed exactly
    14 days ago, but we also want to get rid of older files.
    
  • d601e9a2
    by Ansgar Burchardt at 2019-06-25T21:15:16Z
    link_morgue.sh: suggest `restrict` for ssh authorized_keys entry
    

1 changed file:

Changes:

  • scripts/debian/link_morgue.sh
    ... ... @@ -120,12 +120,12 @@ if [ "$(hostname -s)" != "stabile" ]; then
    120 120
     
    
    121 121
         # We only transfer symlinks or files changed more than 14 days ago
    
    122 122
         # (assuming we won't ever find anything on snapshot for them)
    
    123
    -    find . \( -type l -o \( -type f -ctime 14 \) \) -print0 >${LISTFILE}
    
    123
    +    find . \( -type l -o \( -type f -ctime +14 \) \) -print0 >${LISTFILE}
    
    124 124
     
    
    125 125
         # morgue-sync has to be setup in ~/.ssh/config and the authorized_keys
    
    126 126
         # on the other side should contain (one line, no #)
    
    127 127
     # command="rsync --server -lHogDtpRe.Lsf --remove-source-files . /srv/morgue.debian.org/sync/ftp-master",
    
    128
    -# no-port-forwarding,no-X11-forwarding,no-agent-forwarding,from="ftp-master.debian.org" ssh-rsa...
    
    128
    +# restrict,from="ftp-master.debian.org" ssh-rsa...
    
    129 129
         rsync -aHq -e "ssh -o Batchmode=yes -o ConnectTimeout=30 -o SetupTimeout=30 " --remove-source-files --from0 --files-from=${LISTFILE} $base/morgue/ morgue-sync:/srv/morgue.debian.org/sync/$archive
    
    130 130
     
    
    131 131
         # And remove empty subdirs. To remove entire hierarchies we probably should run this