Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ansible
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
ansible
Commits
06576fed
Commit
06576fed
authored
Dec 05, 2013
by
Wim
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add support for --copy-links
parent
34db2d17
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
library/files/synchronize
+12
-0
No files found.
library/files/synchronize
View file @
06576fed
...
@@ -75,6 +75,12 @@ options:
...
@@ -75,6 +75,12 @@ options:
choices: [ 'yes', 'no' ]
choices: [ 'yes', 'no' ]
default: the value of the archive option
default: the value of the archive option
required: false
required: false
copy_links:
description:
- Copy symlinks as the item that they point to (the referent) is copied, rather than the symlink.
choices: [ 'yes', 'no' ]
default: 'no'
required: false
perms:
perms:
description:
description:
- Preserve permissions.
- Preserve permissions.
...
@@ -163,6 +169,7 @@ def main():
...
@@ -163,6 +169,7 @@ def main():
dirs
=
dict
(
default
=
'no'
,
type
=
'bool'
),
dirs
=
dict
(
default
=
'no'
,
type
=
'bool'
),
recursive
=
dict
(
type
=
'bool'
),
recursive
=
dict
(
type
=
'bool'
),
links
=
dict
(
type
=
'bool'
),
links
=
dict
(
type
=
'bool'
),
copy_links
=
dict
(
type
=
'bool'
),
perms
=
dict
(
type
=
'bool'
),
perms
=
dict
(
type
=
'bool'
),
times
=
dict
(
type
=
'bool'
),
times
=
dict
(
type
=
'bool'
),
owner
=
dict
(
type
=
'bool'
),
owner
=
dict
(
type
=
'bool'
),
...
@@ -185,6 +192,7 @@ def main():
...
@@ -185,6 +192,7 @@ def main():
# the default of these params depends on the value of archive
# the default of these params depends on the value of archive
recursive
=
module
.
params
[
'recursive'
]
recursive
=
module
.
params
[
'recursive'
]
links
=
module
.
params
[
'links'
]
links
=
module
.
params
[
'links'
]
copy_links
=
module
.
params
[
'copy_links'
]
perms
=
module
.
params
[
'perms'
]
perms
=
module
.
params
[
'perms'
]
times
=
module
.
params
[
'times'
]
times
=
module
.
params
[
'times'
]
owner
=
module
.
params
[
'owner'
]
owner
=
module
.
params
[
'owner'
]
...
@@ -201,6 +209,8 @@ def main():
...
@@ -201,6 +209,8 @@ def main():
cmd
=
cmd
+
' --no-recursive'
cmd
=
cmd
+
' --no-recursive'
if
links
is
False
:
if
links
is
False
:
cmd
=
cmd
+
' --no-links'
cmd
=
cmd
+
' --no-links'
if
copy_links
is
True
:
cmd
=
cmd
+
' --copy-links'
if
perms
is
False
:
if
perms
is
False
:
cmd
=
cmd
+
' --no-perms'
cmd
=
cmd
+
' --no-perms'
if
times
is
False
:
if
times
is
False
:
...
@@ -214,6 +224,8 @@ def main():
...
@@ -214,6 +224,8 @@ def main():
cmd
=
cmd
+
' --recursive'
cmd
=
cmd
+
' --recursive'
if
links
is
True
:
if
links
is
True
:
cmd
=
cmd
+
' --links'
cmd
=
cmd
+
' --links'
if
copy_links
is
True
:
cmd
=
cmd
+
' --copy-links'
if
perms
is
True
:
if
perms
is
True
:
cmd
=
cmd
+
' --perms'
cmd
=
cmd
+
' --perms'
if
times
is
True
:
if
times
is
True
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment