Commit f5af9229 authored by Julie gauthier's avatar Julie gauthier
Browse files

BUILD: add automated files modifications

parent fd7a5ddd
......@@ -112,6 +112,49 @@ file { "$_ds_project_directory":
owner => $_system_username,
}
# As long as this is not a pupet module, we don't use a template but 'file_line'.
# Puppuet module should use a template to set proper values.
# Set values for Database and Github Oauth token in config file '.env'
-> file_line { 'DB_DATABASE':
ensure => present,
path => "$_ds_project_directory/.env",
line => 'DB_DATABASE="ds"',
match => '^DB_DATABASE="tps_development"',
}
-> file_line { 'DB_USERNAME':
ensure => present,
path => "$_ds_project_directory/.env",
line => 'DB_USERNAME="ds"',
match => '^DB_USERNAME="tps_development"',
}
-> file_line { 'DB_PASSWORD':
ensure => present,
path => "$_ds_project_directory/.env",
line => 'DB_PASSWORD="kiki34"',
match => '^DB_PASSWORD="tps_development"',
}
-> file_line { 'GITHUB_CLIENT_ID':
ensure => present,
path => "$_ds_project_directory/.env",
line => 'GITHUB_CLIENT_ID="efb23e8a602aac61157c"',
match => '^GITHUB_CLIENT_ID=""',
}
-> file_line { 'GITHUB_CLIENT_SECRET':
ensure => present,
path => "$_ds_project_directory/.env",
line => 'GITHUB_CLIENT_SECRET="ec8f3370372bc4fb381f3f379d5320f1231c2189"',
match => '^GITHUB_CLIENT_SECRET=""',
}
#Modification of bin/setup file.
#As we already create the DB we don't need to recreate it.
file_line { 'db:setup':
ensure => present,
path => "$_ds_project_directory/bin/setup",
line => "system! 'bin/rails db:schema:load db:seed",
match => "^system! 'bin/rails db:setup'",
}
# #############################################################################
# PREREQUISITES ruby
# Install rbenv
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment