Skip to content
This repository has been archived by the owner on Jan 29, 2022. It is now read-only.

Some pre-release fixes #150

Merged
merged 2 commits into from
Aug 29, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions build/vanagon/components/app.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
pkg.environment 'GEM_HOME', '/opt/voxpupuli/webhook/lib/ruby/2.6.0'

pkg.add_source 'file://resources/puppet-webhook.service'
pkg.add_source 'file://resources/puppet-webhook-app.service'
pkg.add_source 'file://resources/puppet-webhook-sidekiq.service'
pkg.add_source 'file://resources/puppetwebhook'
pkg.add_source 'file://resources/postinst.sh'
pkg.add_source 'file://resources/generate_token'
Expand All @@ -42,9 +44,9 @@
]
end

pkg.install_service('../puppet-webhook.service', nil, 'puppet-webhook')
pkg.install_service('../puppet-webhook-app.service', '../puppetwebhook', 'puppet-webhook-app')
pkg.install_service('../puppet-webhook-sidekiq.service', '../puppetwebhook', 'puppet-webhook-sidekiq')
pkg.install_service('../puppet-webhook.service', '../puppetwebhook', 'puppet-webhook')
pkg.install_service('../puppet-webhook-app.service', nil, 'puppet-webhook-app')
pkg.install_service('../puppet-webhook-sidekiq.service', nil, 'puppet-webhook-sidekiq')

pkg.add_postinstall_action('install', 'cd /opt/voxpupuli/webhook && bin/bundle update --bundler')

Expand Down
2 changes: 1 addition & 1 deletion resources/postinst.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ export GEM_PATH=$GEM_HOME
export LD_PATH=/opt/voxpupuli/webhook/lib
export PATH=/opt/voxpupuli/webhook/bin:$PATH

cd /opt/voxpupuli/webhook && bin/bundle install && bin/bundle exec rake db:migrate > /dev/null 2>&1
cd /opt/voxpupuli/webhook && bin/bundle install --with default > /dev/null 2>&1 && bin/bundle exec rake db:migrate > /dev/null 2>&1

echo "Redis is required to start Puppet Webhook. Please install and start Redis first."
1 change: 1 addition & 0 deletions resources/puppetwebhook
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Environment Variables for the Puppet Webhook
WEBHOOK_CONFDIR=/etc/voxpupuli/webhook.yaml
RACK_ENV=production
WORKDIR=/opt/voxpupuli/webhook
RUBYLIB=/opt/voxpupuli/webhook/lib/ruby:/opt/voxpupuli/webhook
GEM_HOME=/opt/voxpupuli/webhook/lib/ruby/gems/2.6.0
GEM_PATH=/opt/voxpupuli/webhook/lib/ruby/gems/2.6.0
Expand Down