commit
0f0838ae5a
|
|
@ -0,0 +1,32 @@
|
||||||
|
pipeline {
|
||||||
|
agent any
|
||||||
|
|
||||||
|
environment {
|
||||||
|
APP_SESSION_SECRET = ''
|
||||||
|
DB_NAME = 'url_shortener.db'
|
||||||
|
}
|
||||||
|
stages {
|
||||||
|
stage('Init') {
|
||||||
|
steps {
|
||||||
|
sh 'rbenv local 3.2.2'
|
||||||
|
script {
|
||||||
|
env.APP_SESSION_SECRET = sh(script: 'ruby secret.rb', returnStdout: true)
|
||||||
|
}
|
||||||
|
sh 'echo "ENV[\\\"APP_SESSION_SECRET\\\"] ||= $(ruby secret.rb)" > .env.rb'
|
||||||
|
sh 'echo "ENV[\\\"DB_NAME\\\"] ||= \\\"${DB_NAME}\\\"" >> .env.rb'
|
||||||
|
sh 'cat .env.rb'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Build dependencies') {
|
||||||
|
steps {
|
||||||
|
sh 'bundle install'
|
||||||
|
sh 'sequel -m db/migrations sqlite://db/${DB_NAME}'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Run tests') {
|
||||||
|
steps {
|
||||||
|
sh 'cucumber'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -5,7 +5,8 @@ Roda, Falcon, Sequel, and SQLite
|
||||||
|
|
||||||
the point of this project is to quickly build something and work on continuous deployment while making small refinements to the functional pieces.
|
the point of this project is to quickly build something and work on continuous deployment while making small refinements to the functional pieces.
|
||||||
|
|
||||||
the only outside piece of software that this project relies on is sqlite3.
|
the outside pieces of software that this project relies on are sqlite3 and pkgconf.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
first you have to install the dependencies:
|
first you have to install the dependencies:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue