In your current before_restart.rb do the following :
current_release = release_path
deploy_node = node
deploy_resource = new_resource
deploy_to = deploy_resource.deploy_to
app_name = deploy_to.split('/')[-1]
deploy_user = deploy_node[:deploy][app_name][:user]
deploy_group = deploy_node[:deploy][app_name][:group]
link "#{current_release}/public/system" do
to "/s3mounted/bucket/public/system"
owner deploy_user
group deploy_group
end
The first part setups the variables I use . If you use something like deploy[] you can end up getting the machines into a deploy loop.
This essentially does the removal of the file for you. When you symlink it automatically does the delete for you.