Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
wattsworth
/
puppet
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
df2930af
authored
Aug 21, 2017
by
John Donnal
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
added nilmdb-fsck service and update docs with journal data info
parent
a55193f9
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
0 deletions
docs/index.rst
modules/nilmdb/files/nilmdb-fsck.service
modules/nilmdb/manifests/init.pp
docs/index.rst
View file @
df2930af
...
...
@@ -28,6 +28,11 @@ Use the Puppet repository to install the complete Wattsworth stack
Here is info about Joule and the Web Frontend
Another edit
Make sure you set up data journaling on the nilmdb partition:
UUID=XXX / ext4 errors=remount-ro,data=journal 0
sudo tune2fs -o journal_data /dev/sda2
.. toctree::
:maxdepth: 2
...
...
modules/nilmdb/files/nilmdb-fsck.service
0 → 100644
View file @
df2930af
[Unit]
Description=check and repair nilmdb database
Before=apache2.service
[Service]
Type=oneshot
StandardOutput=journal
ExecStart = /usr/local/bin/nilmdb-fsck -f -n /opt/nilmdb/db
[Install]
WantedBy=multi-user.target
\ No newline at end of file
modules/nilmdb/manifests/init.pp
View file @
df2930af
...
...
@@ -37,6 +37,7 @@ class nilmdb {
group
=>
root
,
mode
=>
'0644'
,
}
exec
{
'a2ensite 10-nilmdb.conf'
:
creates
=>
'/etc/apache2/sites-enabled/10-nilmdb.conf'
,
path
=>
[
'/usr/sbin'
,
'/usr/bin'
],
...
...
@@ -67,6 +68,19 @@ class nilmdb {
source
=>
'puppet:///modules/nilmdb/nilmdb.wsgi'
,
notify
=>
Exec
[
'nilmdb_restart_apache'
]
}
file
{
'/etc/systemd/system/nilmdb-fsck.service'
:
ensure
=>
present
,
owner
=>
root
,
group
=>
root
,
mode
=>
'0644'
,
source
=>
'puppet:///modules/nilmdb/nilmdb-fsck.service'
,
notify
=>
Exec
[
'install_nilmdb_fsck_service'
]
}
exec
{
'install_nilmdb_fsck_service'
:
command
=>
'/bin/systemctl enable nilmdb-fsck.service'
,
refreshonly
=>
true
,
}
#mod_wsgi tries to access user home directory
#nilmdb is a system account but just create a stub
#directory to satisfy wsgi :P
...
...
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