We have Docker development.
In addition to it you can also use
dip–CLI utility for straightforward provisioning and interacting with an applications configured by
dip copy and run the command below:
gem install dip
# provision application dip provision # run web app dip rails s # or simple dip up web # run rails console dip rails c # run webpacker dip up -d webpacker # `-d` - mean that service will run in detached (background) mode # run migrations dip rake db:migrate # pass env variables into application dip VERSION=20100905201547 rake db:migrate:down # run sidekiq dip up sidekiq # run webhooks receiver ULTRAHOOK_API_KEY=00000 dip compose up webhook # or simple ULTRAHOOK_API_KEY=00000 dip webhook # also you can move ULTRAHOOK_API_KEY variable to ~/.bashrc or ~/.zshrc # run the whole app dip up web sidekiq webpacker # simply launch bash within app directory dip bash # Additional commands # update gems or packages dip bundle install dip yarn install # run psql console dip psql common # where `common` is a database name. It might be `common_test`. # run tests # TIP: `dip rspec` is already auto prefixed with `RAILS_ENV=test` dip rspec spec/path/to/single/test.rb:23 # run functional tests # webpacker should be running with test environment RAILS_ENV=test dip up webpacker dip rspec spec/features # shutdown all containers dip down
Starting from version 3.5, Dip can be easily integrated into ZSH shell, especially if used
agnostic theme. So, there is allow us using all above commands without
dip prefix. And it looks like we are not using Docker at all (really that's not true).
Also, I recommend to install zsh-autosuggestions. And don't use
rails ZSH plugins 'cause Dip is conflicting.
dip console | source /dev/stdin rails c rails s rspec spec/test_spec.rb:23 psql common VERSION=20100905201547 rake db:migrate:down rake routes | grep community
But after we get out to somewhere from the common-admin directory, then all Dip's aliases will be cleared. And if we get back, then Dip's aliases will be restored.