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
f5a43824
authored
Nov 21, 2018
by
John Donnal
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
bug fixes, added chromium and example_modules repo
parent
c72f4c5c
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
69 additions
and
6 deletions
bootstrap.sh
modules/apache/manifests/init.pp
modules/common/files/chromium_policy.json
modules/common/manifests/init.pp
modules/joule/manifests/init.pp
modules/static_sites/files/15-frontend.conf
modules/static_sites/files/20-helpdocs.conf
bootstrap.sh
0 → 100755
View file @
f5a43824
#!/bin/bash
set
-e
echo
"nameserver 172.31.33.1"
>
/etc/resolv.conf
wget https://apt.puppetlabs.com/puppet-release-bionic.deb
dpkg
-i
puppet-release-bionic.deb
add-apt-repository universe
apt-get update
apt install puppet-agent git
-y
/opt/puppetlabs/bin/puppet apply
--verbose
--modulepath
=
./modules site.pp
# create the ubuntu user for the livecd
adduser ubuntu
--quiet
--disabled-password
--gecos
""
echo
-e
'ubuntu\nubuntu\n'
| passwd ubuntu
adduser ubuntu
sudo
adduser ubuntu dialout
modules/apache/manifests/init.pp
View file @
f5a43824
...
...
@@ -22,7 +22,7 @@ class apache {
notify
=>
Exec
[
'add-repo'
]
}
exec
{
'add-repo'
:
command
=>
"/bin/sh -c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger
xenial
main > /etc/apt/sources.list.d/passenger.list' && /usr/bin/apt-get update"
,
command
=>
"/bin/sh -c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger
bionic
main > /etc/apt/sources.list.d/passenger.list' && /usr/bin/apt-get update"
,
refreshonly
=>
true
}
...
...
modules/common/files/chromium_policy.json
0 → 100644
View file @
f5a43824
{
"HomepageLocation"
:
"http://wattsworth.localhost"
,
"HomepageIsNewTabPage"
:
false
,
"RestoreOnStartup"
:
4
,
"RestoreOnStartupURLs"
:
[
"http://wattsworth.localhost"
,
"http://docs.wattsworth.localhost"
],
"ShowHomeButton"
:
true
}
modules/common/manifests/init.pp
View file @
f5a43824
...
...
@@ -3,10 +3,30 @@
# Packages required by multiple modules
#
class
common
{
$pkgs
=
[
'build-essential'
,
'screen'
,
'emacs'
,
'openvpn'
,
'
gnome-tweak-tool'
,
'nmap'
,
'wget'
,
'sqlite3'
,
'gparted
'
]
$pkgs
=
[
'build-essential'
,
'screen'
,
'emacs'
,
'openvpn'
,
'
nmap'
,
'wget'
,
'sqlite3'
,
'gparted'
,
'net-tools'
,
'openssh-server'
,
'chromium-browser
'
]
package
{
$pkgs
:
ensure
=>
present
}
#install chromium policy file
file
{[
'/etc/chromium'
,
'/etc/chromium/policies'
,
'/etc/chromium/policies/managed'
,
'/etc/chromium/policies/recommended'
]:
ensure
=>
directory
,
owner
=>
root
,
group
=>
root
,
}
file
{
'/etc/chromium/policies/managed/policy.json'
:
ensure
=>
present
,
owner
=>
root
,
group
=>
root
,
mode
=>
'0644'
,
source
=>
'puppet:///modules/common/chromium_policy.json'
}
file
{
'/etc/skel/Desktop'
:
ensure
=>
directory
,
}
}
modules/joule/manifests/init.pp
View file @
f5a43824
...
...
@@ -14,7 +14,9 @@
class
joule
{
require
python
require
nilmdb
require
common
$pip_url
=
'https://pypi.wattsworth.net/'
$pip_cmd
=
"pip3 install --upgrade --extra-index-url
${pip_url}
"
...
...
@@ -29,6 +31,23 @@ class joule {
creates
=>
'/etc/joule/main.conf'
,
require
=>
Exec
[
'install_joule'
]
}
user
{
'joule'
:
ensure
=>
present
,
system
=>
true
}
file
{
'/opt/data/joule'
:
ensure
=>
directory
,
owner
=>
joule
,
group
=>
joule
,
require
=>
User
[
'joule'
]
}
vcsrepo
{
'/etc/skel/Desktop/example_modules'
:
ensure
=>
latest
,
provider
=>
git
,
source
=>
'https://git.wattsworth.net/wattsworth/example_modules.git'
,
}
}
modules/static_sites/files/15-frontend.conf
View file @
f5a43824
<
VirtualHost
*:
80
>
ServerName
wattsworth
.
local
ServerName
wattsworth
.
local
host
DocumentRoot
/
var
/
www
/
frontend
Alias
/
api
/
opt
/
api
/
public
<
Directory
/
opt
/
api
/
public
>
...
...
modules/static_sites/files/20-helpdocs.conf
View file @
f5a43824
NameVirtualHost
*:
80
<
VirtualHost
*:
80
>
ServerName
docs
ServerAlias
docs
.
wattsworth
.
local
ServerAlias
docs
.
wattsworth
.
local
host
DocumentRoot
/
var
/
www
/
docs
<
Directory
/
var
/
www
/
docs
/
modules
>
FallbackResource
/
modules
...
...
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