Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
ansible
/
common-playbook
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit bc66a551
authored
Jan 12, 2018
by
ansible
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add disk name "vdb"
1 parent
578a4780
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
0 deletions
formatparition.yml
mountpartition.yml
partitions.yml
formatparition.yml
View file @
bc66a55
...
@@ -24,3 +24,16 @@
...
@@ -24,3 +24,16 @@
-
{
device
:
/dev/sdb3
}
-
{
device
:
/dev/sdb3
}
-
{
device
:
/dev/sdb4
}
-
{
device
:
/dev/sdb4
}
-
hosts
:
vdb-disk
become
:
true
tasks
:
-
name
:
"
Format
disk:
\"
{{
item.device
}}
\"
using
etx4"
filesystem
:
dev
:
"
{{
item.device
}}"
fstype
:
ext4
with_items
:
-
{
device
:
/dev/vdb1
}
-
{
device
:
/dev/vdb2
}
-
{
device
:
/dev/vdb3
}
-
{
device
:
/dev/vdb4
}
mountpartition.yml
View file @
bc66a55
...
@@ -28,3 +28,18 @@
...
@@ -28,3 +28,18 @@
-
{
device
:
/dev/sdb3
,
path
:
/archive
}
-
{
device
:
/dev/sdb3
,
path
:
/archive
}
-
{
device
:
/dev/sdb4
,
path
:
/data
}
-
{
device
:
/dev/sdb4
,
path
:
/data
}
-
hosts
:
vdb-disk
become
:
true
tasks
:
-
name
:
"
Mount
up
\"
{{
item.device
}}
\"
to
\"
{{
item.path
}}
\"
"
mount
:
state
:
mounted
fstype
:
ext4
src
:
"
{{
item.device
}}"
path
:
"
{{
item.path
}}"
with_items
:
-
{
device
:
/dev/vdb1
,
path
:
/opt
}
-
{
device
:
/dev/vdb2
,
path
:
/upload
}
-
{
device
:
/dev/vdb3
,
path
:
/archive
}
-
{
device
:
/dev/vdb4
,
path
:
/data
}
partitions.yml
View file @
bc66a55
...
@@ -32,3 +32,20 @@
...
@@ -32,3 +32,20 @@
-
{
device
:
"
/dev/sdb"
,
number
:
"
2"
,
start
:
"
41%"
,
end
:
"
80%"
}
-
{
device
:
"
/dev/sdb"
,
number
:
"
2"
,
start
:
"
41%"
,
end
:
"
80%"
}
-
{
device
:
"
/dev/sdb"
,
number
:
"
3"
,
start
:
"
81%"
,
end
:
"
90%"
}
-
{
device
:
"
/dev/sdb"
,
number
:
"
3"
,
start
:
"
81%"
,
end
:
"
90%"
}
-
{
device
:
"
/dev/sdb"
,
number
:
"
4"
,
start
:
"
91%"
,
end
:
"
100%"
}
-
{
device
:
"
/dev/sdb"
,
number
:
"
4"
,
start
:
"
91%"
,
end
:
"
100%"
}
-
hosts
:
vdb-disk
become
:
true
tasks
:
-
name
:
Create partiton
parted
:
device
:
"
{{
item.device
}}"
number
:
"
{{
item.number
}}"
part_end
:
"
{{
item.end
}}"
part_start
:
"
{{
item.start
}}"
state
:
present
# part_type: logical
with_items
:
-
{
device
:
"
/dev/vdb"
,
number
:
"
1"
,
start
:
"
0%"
,
end
:
"
40%"
}
-
{
device
:
"
/dev/vdb"
,
number
:
"
2"
,
start
:
"
41%"
,
end
:
"
80%"
}
-
{
device
:
"
/dev/vdb"
,
number
:
"
3"
,
start
:
"
81%"
,
end
:
"
90%"
}
-
{
device
:
"
/dev/vdb"
,
number
:
"
4"
,
start
:
"
91%"
,
end
:
"
100%"
}
Write
Preview
Markdown
is supported
Attach a file
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 post a comment