Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.package
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Arnaud Véron
slapos.package
Commits
0b3d6502
Commit
0b3d6502
authored
Apr 04, 2016
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Playbook: Include include fix for missing centos 6 init.d script.
parent
5082bc0c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
99 additions
and
1 deletion
+99
-1
playbook/roles/re6stnet/files/centos_6_init_d
playbook/roles/re6stnet/files/centos_6_init_d
+82
-0
playbook/roles/re6stnet/tasks/daemon.yml
playbook/roles/re6stnet/tasks/daemon.yml
+10
-0
playbook/roles/re6stnet/tasks/main.yml
playbook/roles/re6stnet/tasks/main.yml
+7
-1
No files found.
playbook/roles/re6stnet/files/centos_6_init_d
0 → 100644
View file @
0b3d6502
#!/bin/bash
#
# /etc/rc.d/init.d/<servicename>
#
# <description of the *service*>
# <any general comments about this init script>
#
# <tags -- see below for tag definitions. *Every line* from the top
# of the file to the end of the tags section must begin with a #
# character. After the tags section, there should be a blank line.
# This keeps normal comments in the rest of the file from being
# mistaken for tags, should they happen to fit the pattern.>
# PATH should only include /usr/* if it runs after the mountnfs.sh script
PATH
=
/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/sbin
NAME
=
re6stnet
DESC
=
"Resilient, Scalable, IPv6 Network application"
DAEMON
=
/opt/re6st/bin/
$NAME
CONFDIR
=
/etc/re6stnet
PIDFILE
=
/var/run/
$NAME
.pid
SCRIPTNAME
=
/etc/init.d/
$NAME
LOCKFILE
=
/var/lock/subsys/re6stnet
# Source function library.
.
/etc/init.d/functions
start
()
{
echo
-n
"Starting
$NAME
: "
daemon
--user
root
-n
$NAME
--pidfile
=
$PIDFILE
-D
$CONFDIR
--
$DAEMON
@re6stnet.conf
RETVAL
=
$?
[
$RETVAL
-eq
0
]
&&
touch
$LOCKFILE
echo
return
$RETVAL
}
stop
()
{
echo
-n
"Shutting down
$NAME
: "
daemon
--user
root
-n
$NAME
--pidfile
=
$PIDFILE
--stop
RETVAL
=
$?
[
$RETVAL
-eq
0
]
&&
rm
-rf
$LOCKFILE
echo
return
$RETVAL
}
status
()
{
echo
-n
"Status for
$NAME
: "
daemon
--user
root
-n
$NAME
--pidfile
=
$PIDFILE
--running
}
restart
()
{
echo
-n
"Restarting
$NAME
: "
daemon
--user
root
-n
$NAME
--pidfile
=
$PIDFILE
-D
$CONFDIR
--restart
--
$DAEMON
@re6stnet.conf
RETVAL
=
$?
[
$RETVAL
-eq
0
]
&&
touch
$LOCKFILE
echo
return
$RETVAL
}
case
"
$1
"
in
start
)
start
;;
stop
)
stop
;;
status
)
status
;;
restart
)
restart
;;
*
)
echo
"Usage: <servicename> {start|stop|status|restart}"
exit
1
;;
esac
exit
$?
playbook/roles/re6stnet/tasks/daemon.yml
0 → 100644
View file @
0b3d6502
---
-
name
:
Install Daemon for CentOS
6
yum
:
name=http://libslack.org/daemon/download/daemon-0.6.4-1.x86_64.rpm state=present
when
:
ansible_distribution == 'CentOS' and ansible_distribution_version <= '6' and ansible_architecture == 'x86_64'
-
name
:
Install Daemon for CentOS 6 (i686)
yum
:
name=http://libslack.org/daemon/download/daemon-0.6.4-1.i686.rpm state=present
when
:
ansible_distribution == 'CentOS' and ansible_distribution_version <= '6' and ansible_architecture == 'i386'
playbook/roles/re6stnet/tasks/main.yml
View file @
0b3d6502
...
...
@@ -28,9 +28,15 @@
register
:
re6stnode
-
name
:
set re6st-node.service file
copy
:
src=/etc/systemd/re6stnet.service dest=/etc/systemd/system/re6st
-node
.service
copy
:
src=/etc/systemd/re6stnet.service dest=/etc/systemd/system/re6st
net
.service
when
:
ansible_distribution == 'CentOS' and ansible_distribution_version >= '7' and re6stnet.stat.exists == True and re6stnode.stat.exists == False
-
include
:
daemon.yml
-
name
:
Create centos 6 init.d missing file
copy
:
src=files/centos_6_init_d dest=/etc/init.d/re6stnet
when
:
ansible_distribution == 'CentOS' and ansible_distribution_version == '6' and recheck_re6stnet_conf.stat.exists == True
-
name
:
Start re6st-node service
service
:
name=re6stnet state=started enabled=yes
when
:
recheck_re6stnet_conf.stat.exists == 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