You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by "macdoor (via GitHub)" <gi...@apache.org> on 2026/03/07 13:52:51 UTC
[PR] [Bug-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
macdoor opened a new pull request, #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036
## Purpose
When the release `tar.gz` is built on macOS, the archive can contain `._*` files, `.DS_Store`, and extended attributes, causing warnings and junk files when extracted on Linux. This change updates `assembly-plugins.sh` so the repack step strips macOS-specific data and produces a Linux-friendly archive.
fixes #18035
## Brief change log
- **dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh**
- Before repacking: remove `._*` and `.DS_Store` under the bin directory.
- On macOS: run `xattr -cr` on the bin directory; repack with `COPYFILE_DISABLE=1` and `tar --no-xattrs` so the final `tar.gz` has no extended attributes.
No changes to `dolphinscheduler-bin.xml` or other assembly descriptors.
Made with [Cursor](https://cursor.com)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2901183177
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,20 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
+# remove macOS junk so Linux extraction is clean
+find "$BIN_DIR" -name '._*' -delete
+find "$BIN_DIR" -name '.DS_Store' -delete
+if [ "$(uname -s)" = "Darwin" ]; then
+ xattr -cr "$BIN_DIR"
+fi
+
# repack bin tar
BIN_TAR_FILE_NAME=$(basename $BIN_TAR_FILE)
-cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+cd $DIST_DIR
+if [ "$(uname -s)" = "Darwin" ]; then
+ COPYFILE_DISABLE=1 tar --no-xattrs -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+else
+ tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+fi
Review Comment:
Hi @SbloodyS,
I kept the shell-script changes on purpose because **macOS `tar` behaves differently from Linux `tar`**, and the repack step in `assembly-plugins.sh` uses the system `tar`.
Flow is:
1. Maven assembly (with the XML `<excludes>`) produces the first `tar.gz`.
2. `assembly-plugins.sh` **extracts** that archive, does mv/ln, then **repacks** with the system `tar -zcf`.
On **macOS**:
- The system `tar` (BSD tar) adds **AppleDouble / resource-fork** entries (`._*`) and can store **extended attributes** when creating archives, unless we tell it not to.
- So even if the first archive is clean (thanks to assembly excludes), the **repack** on macOS can reintroduce junk and xattr, and we see warnings like `tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'` when extracting on Linux.
That's why the script does:
- `find … -delete` for any `._*` / `.DS_Store` that might appear after extract/mv (e.g. from the filesystem).
- On Darwin only: `xattr -cr` and `COPYFILE_DISABLE=1 tar --no-xattrs` so the **repack** doesn't add macOS-specific metadata.
So: the XML excludes handle the assembly output; the script changes are needed for the **repack on macOS** so the final `tar.gz` stays Linux-friendly when built on a Mac. If you still prefer to rely only on XML + .gitignore and drop the script changes (e.g. because official builds are Linux-only), I can revert the script part and keep only the assembly and .gitignore changes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4018984501
Hi @SbloodyS,
I built the package on macOS with the current change (tar `--exclude='._*' --exclude='.DS_Store'`) and extracted the resulting `apache-dolphinscheduler-dev-SNAPSHOT-bin.tar.gz` on Linux. There is still a lot of junk:
```
tar xvfz apache-dolphinscheduler-dev-SNAPSHOT-bin.tar.gz
._apache-dolphinscheduler-dev-SNAPSHOT-bin
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'
apache-dolphinscheduler-dev-SNAPSHOT-bin/
apache-dolphinscheduler-dev-SNAPSHOT-bin/._master-server
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'
apache-dolphinscheduler-dev-SNAPSHOT-bin/master-server/
apache-dolphinscheduler-dev-SNAPSHOT-bin/._ui
...
```
So `--exclude` alone does not stop macOS `tar` from adding `._*` (AppleDouble) entries and extended-attribute headers when **creating** the archive; it only excludes paths when reading the directory. On macOS, the system tar still injects those when packing. To get a clean archive for Linux when building on macOS, we likely need either (1) `COPYFILE_DISABLE=1` and `tar --no-xattrs` (and possibly cleaning `._*` before repack), or (2) to document that the release tar.gz must be built on Linux only.
How would you like to proceed?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4018049792
Hi @SbloodyS,
I kept the shell-script changes on purpose because **macOS `tar` behaves differently from Linux `tar`**, and the repack step in `assembly-plugins.sh` uses the system `tar`.
Flow is:
1. Maven assembly (with the XML `<excludes>`) produces the first `tar.gz`.
2. `assembly-plugins.sh` **extracts** that archive, does mv/ln, then **repacks** with the system `tar -zcf`.
On **macOS**:
- The system `tar` (BSD tar) adds **AppleDouble / resource-fork** entries (`._*`) and can store **extended attributes** when creating archives, unless we tell it not to.
- So even if the first archive is clean (thanks to assembly excludes), the **repack** on macOS can reintroduce junk and xattr, and we see warnings like `tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'` when extracting on Linux.
That's why the script does:
- `find … -delete` for any `._*` / `.DS_Store` that might appear after extract/mv (e.g. from the filesystem).
- On Darwin only: `xattr -cr` and `COPYFILE_DISABLE=1 tar --no-xattrs` so the **repack** doesn't add macOS-specific metadata.
So: the XML excludes handle the assembly output; the script changes are needed for the **repack on macOS** so the final `tar.gz` stays Linux-friendly when built on a Mac. If you still prefer to rely only on XML + .gitignore and drop the script changes (e.g. because official builds are Linux-only), I can revert the script part and keep only the assembly and .gitignore changes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4118157625
@SbloodyS
I verified with official release artifacts from Apache Archive:
_- _3.4.0 package contains ._* entries and LIBARCHIVE.xattr.com.apple.provenance warnings when extracted on Linux.
- 3.4.1 package does not show these issues on the same Linux environment.__
This strongly suggests the packaging environment or packaging process differed between the two releases (e.g., tar implementation / metadata handling), rather than being caused only by local extraction behavior.
```
macdoor@ubuntu2504:~$ tar xvfz apache-dolphinscheduler-3.4.0-bin.tar.gz
._apache-dolphinscheduler-3.4.0-bin
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'
apache-dolphinscheduler-3.4.0-bin/
apache-dolphinscheduler-3.4.0-bin/._master-server
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'
apache-dolphinscheduler-3.4.0-bin/master-server/
apache-dolphinscheduler-3.4.0-bin/._ui
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'
apache-dolphinscheduler-3.4.0-bin/ui/
apache-dolphinscheduler-3.4.0-bin/._api-server
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.provenance'
apache-dolphinscheduler-3.4.0-bin/api-server/
apache-dolphinscheduler-3.4.0-bin/._tools
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2901183177
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,20 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
+# remove macOS junk so Linux extraction is clean
+find "$BIN_DIR" -name '._*' -delete
+find "$BIN_DIR" -name '.DS_Store' -delete
+if [ "$(uname -s)" = "Darwin" ]; then
+ xattr -cr "$BIN_DIR"
+fi
+
# repack bin tar
BIN_TAR_FILE_NAME=$(basename $BIN_TAR_FILE)
-cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+cd $DIST_DIR
+if [ "$(uname -s)" = "Darwin" ]; then
+ COPYFILE_DISABLE=1 tar --no-xattrs -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+else
+ tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+fi
Review Comment:
Hi @SbloodyS, just to confirm: do we only need to build/release the tar.gz on Linux? If we don't consider building on macOS at all, then we don't need to handle macOS tar's special behavior, and I'll revert the script changes (keep only the assembly XML excludes and .gitignore).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2903350751
##########
dolphinscheduler-dist/src/main/assembly/dolphinscheduler-bin.xml:
##########
@@ -29,21 +29,37 @@
<fileSet>
<directory>${basedir}/../dolphinscheduler-alert/dolphinscheduler-alert-server/target/alert-server</directory>
<outputDirectory>alert-server</outputDirectory>
+ <excludes>
+ <exclude>**/._*</exclude>
+ <exclude>**/.DS_Store</exclude>
+ </excludes>
Review Comment:
It is best to move this operation to each module for processing.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4018416254
## [](https://sonarcloud.io/dashboard?id=apache-dolphinscheduler&pullRequest=18036) **Quality Gate passed**
Issues
 [0 New issues](https://sonarcloud.io/project/issues?id=apache-dolphinscheduler&pullRequest=18036&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache-dolphinscheduler&pullRequest=18036&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache-dolphinscheduler&pullRequest=18036&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache-dolphinscheduler&pullRequest=18036&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache-dolphinscheduler&pullRequest=18036&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache-dolphinscheduler&pullRequest=18036)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4020781465
I packed it with m1 pro chip. And Unzipped in ubuntu24.04. I still can't reproduce your problem. This problem can be ignored for the time being.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "ruanwenjun (via GitHub)" <gi...@apache.org>.
ruanwenjun commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2922336827
##########
pom.xml:
##########
@@ -797,6 +797,28 @@
<artifactId>maven-dependency-plugin</artifactId>
<version>${maven-dependency-plugin.version}</version>
</plugin>
+ <!-- Remove macOS junk from each module's target so assembly picks up clean output -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>3.1.0</version>
+ <executions>
+ <execution>
+ <id>clean-macos-junk</id>
+ <phase>package</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <target>
+ <delete failonerror="false">
+ <fileset dir="${project.build.directory}" includes="**/._*, **/.DS_Store, ._*, .DS_Store" />
+ </delete>
+ </target>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
Review Comment:
We don't need to add this, we use `fileSets` to collect the file, we already exclude this
```
<exclude>**/.DS_Store</exclude>
<exclude>**/Thumbs.db</exclude>
```
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,8 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
-# repack bin tar
+# repack bin tar (exclude macOS junk so extraction on Linux is clean)
BIN_TAR_FILE_NAME=$(basename $BIN_TAR_FILE)
-cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME --exclude='._*' --exclude='.DS_Store' apache-dolphinscheduler-*-bin
Review Comment:
This is caused by you open the directory by finder?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4046450178
Hi @ruanwenjun,
The root cause of this issue is macOS `tar` (bsdtar) behavior — it automatically embeds `._*` (AppleDouble) entries and extended attribute headers into the archive when **creating** a tarball, even if no `._*` files exist on disk. This is a well-known cross-platform issue:
https://superuser.com/questions/61185/why-do-i-get-files-like-foo-in-my-tarball-on-os-x
> OS X's tar uses the AppleDouble format to store extended attributes and ACLs. [...] You can tell tar to not include the metadata by setting `COPYFILE_DISABLE` to some value.
So it's not caused by opening the directory in Finder — it happens whenever macOS bsdtar packs any file that has extended attributes (which macOS adds silently, e.g. `com.apple.provenance`).
Regarding `<exclude>` in `fileSets`: the `<exclude>` in `dolphinscheduler-bin.xml` works for filtering **physical files** from the source directories, but it cannot prevent macOS bsdtar from **injecting** `._*` entries and xattr headers into the tar stream at creation time. That's why `--exclude` alone was not sufficient when I tested it.
That said, @SbloodyS mentioned he couldn't reproduce this on his M1 Pro environment, so this may depend on the specific macOS/bsdtar version. If you think we can ignore the macOS build case for now, I'm happy to simplify this PR to just keep the `<exclude>` entries in `dolphinscheduler-bin.xml` and the `.gitignore` change, and remove the `maven-antrun-plugin` and `tar --exclude` changes. Let me know how you'd like to proceed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4020647596
I used the current PR compiler in my environment and didn't find the file and warning you mentioned. And I didn't find the corresponding file in the published binary package. Please recheck your environment. @macdoor
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4020801281
Hi @SbloodyS, I'm fine with leaving this as-is for now (e.g. document that the release tar.gz should be built on Linux if needed). We can revisit the macOS build case later if required.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4115646929
This issue cannot be reproduced at present. Closing for now.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2901169788
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,20 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
+# remove macOS junk so Linux extraction is clean
+find "$BIN_DIR" -name '._*' -delete
+find "$BIN_DIR" -name '.DS_Store' -delete
+if [ "$(uname -s)" = "Darwin" ]; then
+ xattr -cr "$BIN_DIR"
+fi
+
# repack bin tar
BIN_TAR_FILE_NAME=$(basename $BIN_TAR_FILE)
-cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+cd $DIST_DIR
+if [ "$(uname -s)" = "Darwin" ]; then
+ COPYFILE_DISABLE=1 tar --no-xattrs -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+else
+ tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+fi
Review Comment:
This is still unaddressed. You should revert this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2901280629
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,20 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
+# remove macOS junk so Linux extraction is clean
+find "$BIN_DIR" -name '._*' -delete
+find "$BIN_DIR" -name '.DS_Store' -delete
+if [ "$(uname -s)" = "Darwin" ]; then
+ xattr -cr "$BIN_DIR"
+fi
+
# repack bin tar
BIN_TAR_FILE_NAME=$(basename $BIN_TAR_FILE)
-cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+cd $DIST_DIR
+if [ "$(uname -s)" = "Darwin" ]; then
+ COPYFILE_DISABLE=1 tar --no-xattrs -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+else
+ tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+fi
Review Comment:
You can simply adding `--exclude` to tar. Try to avoid too much extra logic in the packaging process.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4020737992
Hi @SbloodyS, I ran the test again with the same result (junk and xattr warnings on Linux). Here is my environment for comparison:
**Packaging (build) environment (macOS):**
```
macdoor@macdoorMacBook dolphinscheduler % uname -a
Darwin localhost 25.4.0 Darwin Kernel Version 25.4.0: Wed Feb 25 21:03:15 PST 2026; root:xnu-12377.100.630.501.3~2/RELEASE_ARM64_T6000 arm64
macdoor@macdoorMacBook dolphinscheduler % tar --version
bsdtar 3.5.3 - libarchive 3.7.4 zlib/1.2.12 liblzma/5.4.3 bz2lib/1.0.8
```
**Extraction environment (Linux):**
```
macdoor@ubuntu2510:~$ uname -a
Linux ubuntu2510 6.17.0-14-generic #14-Ubuntu SMP PREEMPT_DYNAMIC Fri Jan 9 17:01:16 UTC 2026 x86_64 GNU/Linux
macdoor@ubuntu2510:~$ tar --version
tar (GNU tar) 1.35
Copyright (C) 2023 Free Software Foundation, Inc.
...
Written by John Gilmore and Jay Fenlason.
```
So the package is **created** with **bsdtar** on macOS (ARM64), then **extracted** with **GNU tar** on Ubuntu. The `._*` entries and `LIBARCHIVE.xattr.com.apple.provenance` warnings still appear. If your test was on Linux-only (build and extract on Linux), that would explain the difference.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS closed pull request #18036: [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction
URL: https://github.com/apache/dolphinscheduler/pull/18036
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2924368956
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,8 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
-# repack bin tar
+# repack bin tar (exclude macOS junk so extraction on Linux is clean)
BIN_TAR_FILE_NAME=$(basename $BIN_TAR_FILE)
-cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME apache-dolphinscheduler-*-bin
+cd $DIST_DIR && tar -zcf $BIN_TAR_FILE_NAME --exclude='._*' --exclude='.DS_Store' apache-dolphinscheduler-*-bin
Review Comment:
> This is caused by you open the directory by finder?
Hi @ruanwenjun,
The root cause of this issue is macOS `tar` (bsdtar) behavior — it automatically embeds `._*` (AppleDouble) entries and extended attribute headers into the archive when **creating** a tarball, even if no `._*` files exist on disk. This is a well-known cross-platform issue:
https://superuser.com/questions/61185/why-do-i-get-files-like-foo-in-my-tarball-on-os-x
> OS X's tar uses the AppleDouble format to store extended attributes and ACLs. [...] You can tell tar to not include the metadata by setting `COPYFILE_DISABLE` to some value.
So it's not caused by opening the directory in Finder — it happens whenever macOS bsdtar packs any file that has extended attributes (which macOS adds silently, e.g. `com.apple.provenance`).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "macdoor (via GitHub)" <gi...@apache.org>.
macdoor commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4018076821
Hi @SbloodyS, just to confirm: do we only need to build/release the tar.gz on Linux? If we don't consider building on macOS at all, then we don't need to handle macOS tar's special behavior, and I'll revert the script changes (keep only the assembly XML excludes and .gitignore).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#issuecomment-4018413801
## [](https://sonarcloud.io/dashboard?id=apache-dolphinscheduler&pullRequest=18036) **Quality Gate passed**
Issues
 [0 New issues](https://sonarcloud.io/project/issues?id=apache-dolphinscheduler&pullRequest=18036&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache-dolphinscheduler&pullRequest=18036&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache-dolphinscheduler&pullRequest=18036&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache-dolphinscheduler&pullRequest=18036&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache-dolphinscheduler&pullRequest=18036&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache-dolphinscheduler&pullRequest=18036)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Improvement-18035][dist] Exclude macOS junk from bin tar.gz for clean Linux extraction [dolphinscheduler]
Posted by "SbloodyS (via GitHub)" <gi...@apache.org>.
SbloodyS commented on code in PR #18036:
URL: https://github.com/apache/dolphinscheduler/pull/18036#discussion_r2899836828
##########
dolphinscheduler-dist/src/main/assembly/assembly-plugins.sh:
##########
@@ -77,8 +77,20 @@ done
# create symbolic link for standalone-server
cd $BIN_DIR/standalone-server && ln -s ../tools/sql/sql sql
+# remove macOS junk so Linux extraction is clean
Review Comment:
We should exclude file in `maven-assembly-plugin` and `.gitignore`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org