Skip to content

Commit b15439e

Browse files
Ansible Collection v1.0.5 Release update (#669)
* Ansible Collection v1.0.5 Release update * Ansible Collection v1.0.5 Release update * Ansible Collection v1.0.5 Release update * Ansible Collection v1.0.5 Release update * Ansible Collection v1.0.5 Release update
1 parent 5c50735 commit b15439e

File tree

6 files changed

+148
-30
lines changed

6 files changed

+148
-30
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ should be added to the Ansible configuration file in order to allow the jsnapy c
7474

7575
[Official Juniper documentation](http://www.juniper.net/techpubs/en_US/release-independent/junos-ansible/information-products/pathway-pages/index.html) (detailed information, including examples)
7676

77-
[Ansible style documentation](https://ansible-juniper-collection.readthedocs.io/en/latest/)
77+
[Ansible style documentation](https://ansible-juniper-collection.readthedocs.io)
7878

7979
## INSTALLATION
8080

Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
.. _file_copy:
2+
3+
file_copy
4+
+++++++++
5+
File put and get module
6+
7+
8+
9+
.. contents::
10+
:local:
11+
:depth: 2
12+
13+
14+
Synopsis
15+
--------
16+
17+
18+
* Copy file over SCP to and from a Juniper device
19+
20+
21+
.. _module-specific-options-label:
22+
23+
Module-specific Options
24+
-----------------------
25+
The following options may be specified for this module:
26+
27+
.. raw:: html
28+
29+
<table border=1 cellpadding=4>
30+
31+
<tr>
32+
<th class="head">parameter</th>
33+
<th class="head">type</th>
34+
<th class="head">required</th>
35+
<th class="head">default</th>
36+
<th class="head">choices</th>
37+
<th class="head">comments</th>
38+
</tr>
39+
40+
<tr>
41+
<td>action<br/><div style="font-size: small;"></div></td>
42+
<td>str</td>
43+
<td>yes</td>
44+
<td></td>
45+
<td></td>
46+
<td>
47+
<div>Type of operation to execute, currently only support get and put</div>
48+
</td>
49+
</tr>
50+
51+
<tr>
52+
<td>file<br/><div style="font-size: small;"></div></td>
53+
<td>str</td>
54+
<td>yes</td>
55+
<td></td>
56+
<td></td>
57+
<td>
58+
<div>Name of the file to copy to/from the remote device</div>
59+
</td>
60+
</tr>
61+
62+
<tr>
63+
<td>local_dir<br/><div style="font-size: small;"></div></td>
64+
<td>str</td>
65+
<td>yes</td>
66+
<td></td>
67+
<td></td>
68+
<td>
69+
<div>path of the local directory where the file is located or needs to be copied to</div>
70+
</td>
71+
</tr>
72+
73+
<tr>
74+
<td>remote_dir<br/><div style="font-size: small;"></div></td>
75+
<td>str</td>
76+
<td>yes</td>
77+
<td></td>
78+
<td></td>
79+
<td>
80+
<div>path of the directory on the remote device where the file is located or needs to be copied to</div>
81+
</td>
82+
</tr>
83+
84+
</table>
85+
</br>
86+
87+
.. _file_copy-examples-label:
88+
89+
Examples
90+
--------
91+
92+
::
93+
94+
95+
---
96+
- name: Examples of juniper_device_file_copy
97+
hosts: all
98+
connection: local
99+
gather_facts: false
100+
tasks:
101+
- name: Copy a log file on a remote device locally
102+
juniper.device.file_copy:
103+
remote_dir: /var/log
104+
local_dir: /tmp
105+
action: get
106+
file: log.txt
107+
- name: Copy a local file into /var/tmp on the remote device
108+
juniper.device.file_copy:
109+
remote_dir: /var/tmp
110+
local_dir: /tmp
111+
action: put
112+
file: license.txt
113+
114+
115+
116+
117+
118+
Author
119+
~~~~~~
120+
121+
* Juniper Networks - Dinesh Babu (@dineshbaburam91)
122+
123+
124+
125+
126+
Status
127+
~~~~~~
128+
129+
This module is flagged as **stableinterface** which means that the maintainers for this module guarantee that no backward incompatible interface changes will be made.
130+

ansible_collections/juniper/device/galaxy.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ namespace: juniper
99
name: device
1010

1111
# The version of the collection. Must be compatible with semantic versioning
12-
version: 1.0.4
12+
version: 1.0.5
1313

1414
# The path to the Markdown (.md) readme file. This path is relative to the root of the collection
1515
readme: README.md

ansible_collections/juniper/device/plugins/modules/file_copy.py

Lines changed: 12 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -43,44 +43,32 @@
4343
- juniper_junos_common.connection_documentation
4444
- juniper_junos_common.logging_documentation
4545
module: file_copy
46-
author: Juniper Networks - Dinesh babu (@dineshbaburam91)
46+
author: "Juniper Networks - Dinesh Babu (@dineshbaburam91)"
47+
short_description: File put and get over SCP module
4748
description:
48-
- Copy file over SCP to and from a Juniper device
49+
- Copy file over SCP to and from a Juniper device
4950
options:
50-
local_dir=dict(type='str',
51-
required=True,
52-
default=None),
53-
remote_dir=dict(type='str',
54-
required=True,
55-
default=None),
56-
file=dict(type='str',
57-
required=True,
58-
default=None),
59-
action=dict(type='str',
60-
choices=['put', 'get'],
61-
required=True,
62-
default=None)
6351
local_dir:
6452
description:
65-
- path of the local directory where the file is located
66-
or needs to be copied to
67-
required: True
53+
- path of the local directory where the file is located
54+
or needs to be copied to
55+
required: true
6856
type: str
6957
remote_dir:
7058
description:
71-
- path of the directory on the remote device where the file is located
72-
or needs to be copied to
73-
required: True
59+
- path of the directory on the remote device where the file is located
60+
or needs to be copied to
61+
required: true
7462
type: str
7563
file:
7664
description:
77-
- Name of the file to copy to/from the remote device.
65+
- Name of the file to copy to/from the remote device
7866
required: true
7967
type: str
80-
Action:
68+
action:
8169
description:
8270
- Type of operation to execute, currently only support get and put
83-
required: True
71+
required: true
8472
type: str
8573
'''
8674

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
VERSION = "v1.0.4-collections"
2-
DATE = "2024-Apr-30"
1+
VERSION = "v1.0.5-collections"
2+
DATE = "2024-May-22"

version.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
VERSION = "v1.0.4-collections"
2-
DATE = "2024-Apr-30"
1+
VERSION = "v1.0.5-collections"
2+
DATE = "2024-May-22"

0 commit comments

Comments
 (0)