]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
only add and update files, never delete
authormilzi234 <fla@synapps.de>
Fri, 14 Feb 2025 12:11:43 +0000 (13:11 +0100)
committermilzi234 <fla@synapps.de>
Tue, 18 Feb 2025 08:34:06 +0000 (09:34 +0100)
.github/workflows/documentation.yml

index 163d9d5a117afef2b7412dd3763de64f621c5d5d..911165b24c2bbb2872c342eaee2532d19539f698 100644 (file)
@@ -286,15 +286,26 @@ jobs:
           if [ -n "$AWS_CLOUDFRONT_DISTRIBUTION_ID_DNSDIST" ]; then
             tar -xf artifacts/dnsdist-html-docs-${{needs.build-docs.outputs.pdns_version}}/dnsdist-html-docs.tar
             cp artifacts/dnsdist-${{needs.build-docs.outputs.pdns_version}}.pdf/dnsdist.pdf dnsdist-html-docs/
-            node .github/scripts/publish.js publish dnsdist.org dnsdist-html-docs /
-          fi
-          if [ -n "$AWS_CLOUDFRONT_DISTRIBUTION_ID_DOCS" ]; then
-            tar -xf artifacts/recursor-html-docs-${{needs.build-docs.outputs.pdns_version}}/rec-html-docs.tar
-            cp artifacts/PowerDNS-Recursor-${{needs.build-docs.outputs.pdns_version}}.pdf/PowerDNS-Recursor.pdf rec-html-docs/
-            node .github/scripts/publish.js publish docs.powerdns.com rec-html-docs /recursor
+            rclone copy dnsdist-html-docs/ docs-s3:$AWS_S3_BUCKET_DOCS/dnsdist.org/
+            # Invalidate CloudFront cache for DNSdist
+            aws cloudfront create-invalidation \
+              --distribution-id $AWS_CLOUDFRONT_DISTRIBUTION_ID_DNSDIST \
+              --paths "/*"
+                      fi
+                      if [ -n "$AWS_CLOUDFRONT_DISTRIBUTION_ID_DOCS" ]; then
+                        tar -xf artifacts/recursor-html-docs-${{needs.build-docs.outputs.pdns_version}}/rec-html-docs.tar
+                        cp artifacts/PowerDNS-Recursor-${{needs.build-docs.outputs.pdns_version}}.pdf/PowerDNS-Recursor.pdf rec-html-docs/
+            rclone copy rec-html-docs/ docs-s3:$AWS_S3_BUCKET_DOCS/docs.powerdns.com/recursor/
+
             tar -xf artifacts/authoritative-html-docs-${{needs.build-docs.outputs.pdns_version}}/auth-html-docs.tar
             cp artifacts/PowerDNS-Authoritative-${{needs.build-docs.outputs.pdns_version}}.pdf/PowerDNS-Authoritative.pdf auth-html-docs/
-            node .github/scripts/publish.js publish docs.powerdns.com auth-html-docs /authoritative
+            rclone copy auth-html-docs/ docs-s3:$AWS_S3_BUCKET_DOCS/docs.powerdns.com/authoritative/
+
             tar -xf artifacts/website-${{needs.build-docs.outputs.pdns_version}}/website.tar
-            node .github/scripts/publish.js publish docs.powerdns.com website/docs.powerdns.com /
-          fi
+            rclone copy website/docs.powerdns.com/ docs-s3:$AWS_S3_BUCKET_DOCS/docs.powerdns.com/
+
+            # Invalidate CloudFront cache for docs.powerdns.com
+            aws cloudfront create-invalidation \
+              --distribution-id $AWS_CLOUDFRONT_DISTRIBUTION_ID_DOCS \
+              --paths "/*"
+                      fi