Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-52209

Portal sync scripts do not remove deleted files

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • 4.13.z, 4.12.z, 4.14.z, 4.15.z, 4.17.z, 4.16.z, 4.18.z, 4.19
    • Documentation
    • None
    • None
    • False
    • Hide

      None

      Show
      None

      Description of problem:

      Portal sync scripts do not remove deleted files. This means that there are lots of older, moved, or deleted files in the doc-4.x portal repos.
      Portal builds do not use files that are not in the master.adoc, so it is not a crtical error, however, it should still be corrected - Troubleshooting AsciiDoc errors will be more difficult when there are out of date files in the repo.

      Version-Release number of selected component (if applicable):

      All versions (?)

      How reproducible:

      Run a sync build and compare to the drupal-build/ folder in openshift-docs github.
      Out of date and missing files in the folder comparison     

      How to fix - update sync.sh for all branches:

      Update the rsync command in sync.sh to use the --delete switch.
      
      --delete
             This tells rsync to delete extraneous files from the receiving  side  (ones  that  aren’t  on  the
             sending  side),  but  only  for  the directories that are being synchronized.

      # now copy the content from the build earlier
      for d in */ ; do
        echo "$d"
        rsync -rvq --delete --exclude=docinfo.xml ../openshift-docs/drupal-build/openshift-enterprise/${d} ${d}
      done

       

              ocp-docs-bot OCP DocsBot
              rhn-support-aireilly Aidan Reilly
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: