add dev update script
This commit is contained in:
parent
1921796050
commit
51e822f49a
27
dist/update-dev.sh
vendored
Executable file
27
dist/update-dev.sh
vendored
Executable file
|
@ -0,0 +1,27 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
function installRuby {
|
||||
rbMasto=`cat .ruby-version`
|
||||
rbVersions=`rbenv versions`
|
||||
|
||||
# build and install ruby with jemalloc
|
||||
if [[ *$rbMasto* == $rbVersions ]]; then
|
||||
RUBY_CONFIGURE_OPTS=--with-jemalloc rbenv install $rbMasto
|
||||
fi
|
||||
}
|
||||
|
||||
function installMastoDeps {
|
||||
bundle install -j$(getconf _NPROCESSORS_ONLN)
|
||||
yarn install
|
||||
|
||||
# setup db
|
||||
bundle exec rails db:migrate
|
||||
}
|
||||
|
||||
installRuby
|
||||
installMastoDeps
|
||||
|
||||
# Done!
|
||||
echo "Setup done! Run 'foreman start' to start sidekiq, streaming, web, and webpack
|
||||
Username: admin@localhost:3000
|
||||
Password: mastodonadmin"
|
Loading…
Reference in a new issue