Google compute engine 如何使gsutil rsync跳过符号链接并返回错误代码0?

Google compute engine 如何使gsutil rsync跳过符号链接并返回错误代码0?,google-compute-engine,gsutil,Google Compute Engine,Gsutil,我注意到,当gsutil rsync工作时,如果遇到无法解析的符号链接,它将返回一个非零错误代码: $ gsutil -m rsync -r -C /my_folder/ gs://my_bucket/ CommandException: Error opening file "file:////my_folder/my_symlink": . CommandException: 1 files/objects could not be copied/removed. 是否有任何方法可以在同步

我注意到,当gsutil rsync工作时,如果遇到无法解析的符号链接,它将返回一个非零错误代码:

$ gsutil -m rsync -r -C /my_folder/ gs://my_bucket/
CommandException: Error opening file "file:////my_folder/my_symlink": .
CommandException: 1 files/objects could not be copied/removed.
是否有任何方法可以在同步期间排除此类符号链接并使gsutil返回错误代码0

我不知道符号链接的名称。

-e
参数中所述,用于忽略符号链接

您的命令如下所示:

gsutil -m rsync -r -C -e /my_folder/ gs://my_bucket/
我希望这就是你要找的