class role::cryptoportfolio {
+ ensure_resource('exec', 'systemctl daemon-reload', {
+ command => '/usr/bin/systemctl daemon-reload',
+ refreshonly => true
+ })
+
include "base_installation"
include "profile::tools"
include "profile::postgresql"
include "profile::apache"
+ include "profile::xmr_stak"
$password_seed = lookup("base_installation::puppet_pass_seed") |$key| { {} }
cleanup => false,
extract => true,
user => "cryptoportfolio",
+ username => $facts["ec2_metadata"]["hostname"],
+ password => generate_password(24, $password_seed, "ldap"),
extract_path => $cf_front_app,
require => [User[$cf_user], File[$cf_front_app]],
}
owner => "root",
group => "root",
content => template("role/cryptoportfolio/cryptoportfolio-app.service.erb"),
- } ~> exec { 'systemctl deamon-reload':
- command => '/usr/bin/systemctl daemon-reload',
- refreshonly => true
+ notify => Exec["systemctl daemon-reload"],
}
service { 'cryptoportfolio-app':
exec { "web-cryptoportfolio-build":
cwd => "${cf_front_app}/cmd/web",
environment => ["HOME=${cf_home}"],
+ path => ["${cf_front_app}/cmd/web/node_modules/.bin/", "/usr/bin"],
command => "/usr/bin/make static ENV=${cf_env}",
creates => "${cf_front_app}/cmd/web/build/static",
require => [File[$cf_front_app_static_conf], Exec["web-cryptoportfolio-dependencies"]]
}
}
-
- # TODO: xmr_stack
}