Skip to content
Noriyo Akita edited this page Feb 19, 2018 · 4 revisions

Welcome to the gitfab2 wiki!

開発に参加するには

Requirements

  • Docker 17 ce or later
  • Docker Compose 1.16 or later
  • direnv
  • rbenv

Installation

  1. Fork it (https://github.com/webdino/gitfab2/fork)
$ git clone git@github.com:<your_account>/gitfab2.git
$ cd gitfab2
$ rbenv install `cat .ruby-version`
$ gem install bundler --no-document
$ bundle install
$ cp config/database.ymls/development.yml config/database.yml
$ cp .envrc.sample .envrc
$ vi .envrc
$ direnv allow

Start Docker Compose

$ docker-compose up -d
$ docker-compose ps
              Name                             Command               State            Ports
----------------------------------------------------------------------------------------------------
gitfab2_db_1                 docker-entrypoint.sh --inn ...   Up      0.0.0.0:13306->3306/tcp

Create database

Dockerコンテナを起動してから

$ bundle exec rake db:create
$ bundle exec ridgepole -c config/database.yml -E development --apply -f db/schemas/Schemafile
$ bundle exec ridgepole -c config/database.yml -E test --apply -f db/schemas/Schemafile

Run Server

$ bundle exec rails s
[DEPRECATION] requiring "RMagick" is deprecated. Use "rmagick" instead
warning: parser/current is loading parser/ruby21, which recognizes
warning: 2.1.6-compliant syntax, but you are running 2.1.2.
warning: please see https://github.com/whitequark/parser#compatibility-with-ruby-mri.
=> Booting WEBrick
=> Rails 4.1.16 application starting in development on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Notice: server is listening on all interfaces (0.0.0.0). Consider using 127.0.0.1 (--binding option)
=> Ctrl-C to shutdown server
[2017-11-01 14:47:18] INFO  WEBrick 1.3.1
[2017-11-01 14:47:19] INFO  ruby 2.1.2 (2014-05-08) [x86_64-linux]
[2017-11-01 14:47:19] INFO  WEBrick::HTTPServer#start: pid=6533 port=3000

Open http://localhost:3000 in your browser.

  1. Create a feature branch
  2. Commit your changes
  3. Rebase your local changes against the develop branch
  4. Create new Pull Request

Related Repository