Commit f5a43824 by John Donnal

bug fixes, added chromium and example_modules repo

parent c72f4c5c
#!/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
......@@ -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
}
......
{
"HomepageLocation": "http://wattsworth.localhost",
"HomepageIsNewTabPage": false,
"RestoreOnStartup": 4,
"RestoreOnStartupURLs": ["http://wattsworth.localhost","http://docs.wattsworth.localhost"],
"ShowHomeButton": true
}
......@@ -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,
}
}
......@@ -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',
}
}
<VirtualHost *:80>
ServerName wattsworth.local
ServerName wattsworth.localhost
DocumentRoot /var/www/frontend
Alias /api /opt/api/public
<Directory /opt/api/public>
......
NameVirtualHost *:80
<VirtualHost *:80>
ServerName docs
ServerAlias docs.wattsworth.local
ServerAlias docs.wattsworth.localhost
DocumentRoot /var/www/docs
<Directory /var/www/docs/modules>
FallbackResource /modules
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment