Simplify installation commands
Sometimes running `bin/rake db:create` doesn't work properly returning an error message about a database not existing. So we'll execute `rake`. New users should only have one version of `rake` installed, so executing `rake` will work fine. On the other hand, the opposite happens sometimes when executing `rails s`. So executing `bin/rails s` works in every case.
This commit is contained in:
committed by
voodoorai2000
parent
2ee4ff69e1
commit
924503fa09
@@ -12,7 +12,7 @@ git clone https://github.com/consul/consul.git
|
||||
|
||||
```bash
|
||||
cd consul
|
||||
bundle install
|
||||
bundle
|
||||
```
|
||||
|
||||
3. Copy the environment example configuration files inside new readable ones:
|
||||
@@ -27,22 +27,22 @@ And setup database credentials with your `consul` user in your new `database.yml
|
||||
4. Run the following [Rake tasks](https://github.com/ruby/rake) to create and fill your local database with the minimum data to run the application:
|
||||
|
||||
```bash
|
||||
bin/rake db:create
|
||||
bin/rake db:setup
|
||||
bin/rake db:dev_seed
|
||||
RAILS_ENV=test bin/rake db:setup
|
||||
rake db:create
|
||||
rake db:setup
|
||||
rake db:dev_seed
|
||||
rake db:test:prepare
|
||||
```
|
||||
|
||||
5. Check everything is fine by running the test suite (beware it takes some long minutes):
|
||||
5. Check everything is fine by running the test suite (beware it might take more than an hour):
|
||||
|
||||
```bash
|
||||
bundle exec rspec
|
||||
bin/rspec
|
||||
```
|
||||
|
||||
6. Now you have all set, run the application:
|
||||
|
||||
```bash
|
||||
rails s
|
||||
bin/rails s
|
||||
```
|
||||
|
||||
Congratulations! Your local Consul application will be running now at `http://localhost:3000`.
|
||||
|
||||
@@ -12,7 +12,7 @@ git clone https://github.com/consul/consul.git
|
||||
|
||||
```bash
|
||||
cd consul
|
||||
bundle install
|
||||
bundle
|
||||
```
|
||||
|
||||
3. Copia los archivos de configuración de ejemplo del entorno dentro de unos nuevos válidos:
|
||||
@@ -27,22 +27,22 @@ Y configura los de tu usuario de base de datos `consul` en `database.yml`
|
||||
4. Ejecuta las siguientes [tareas Rake](https://github.com/ruby/rake) para crear y rellenar tu base de datos local con el mínimo de información necesaria para que la aplicación funcione correctamente:
|
||||
|
||||
```bash
|
||||
bin/rake db:create
|
||||
bin/rake db:setup
|
||||
bin/rake db:dev_seed
|
||||
RAILS_ENV=test bin/rake db:setup
|
||||
rake db:create
|
||||
rake db:setup
|
||||
rake db:dev_seed
|
||||
rake db:test:prepare
|
||||
```
|
||||
|
||||
5. Comprueba que todo funciona correctamente lanzando la suite de tests (ten en cuenta que tardará unos cuantos minutos):
|
||||
5. Comprueba que todo funciona correctamente lanzando la suite de tests (ten en cuenta que podría tardar más de una hora):
|
||||
|
||||
```bash
|
||||
bundle exec rspec
|
||||
bin/rspec
|
||||
```
|
||||
|
||||
6. Ahora que ya está todo listo puedes ejecutar la aplicación:
|
||||
|
||||
```bash
|
||||
rails s
|
||||
bin/rails s
|
||||
```
|
||||
|
||||
¡Felicidades! Tu aplicación Consul local estará corriendo en `http://localhost:3000`.
|
||||
|
||||
Reference in New Issue
Block a user