Redmine is a flexible project management web application written using Ruby on Rails framework.
More details can be found in the doc directory or on the official website
- Install postgresql 10.23 via following command:
./postgress.exe --install_runtimes 0
-
Install rubyinstaller+devkit 3.0
-
Compile xapian-core and xapian-bindings for windows from here (from bash with unix tools):
cd {folder_with_packages}
tar -xJf {core}.tar.xz
tar -xJf {bindings}.tar.xz
cd {core}
./configure
make
make install
cd ../{bindings}
./configure --with-ruby LDFLAGS='-L{path_to_ruby_folder}/lib' RUBY_LIB={path_to_site_lib} RUBY_LIB_ARCH={path_to_site_lib}
make
make install
- Install nginx
- Create database and user for redmine
CREATE ROLE redmine LOGIN ENCRYPTED PASSWORD 'my_password' NOINHERIT VALID UNTIL 'infinity';
CREATE DATABASE redmine WITH ENCODING='UTF8' OWNER=redmine;
ALTER DATABASE "redmine_db" SET datestyle="ISO,MDY"
- Setup database.yml in config folder
production:
adapter: postgresql
database: <your_database_name>
host: <postgres_host>
username: <postgres_user>
password: "<postgres_user_password>"
encoding: utf8
schema_search_path: <database_schema> (default - public)
- Setup nginx congiguration
server {
listen 3001;
root C:/redmine/public;
try_files $uri/index.html $uri @redmine;
upstream redmine {
server 127.0.0.1:3000;
}
location @redmine {
proxy_pass http://redmine;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
}
}
- Load submodules with plugins, more information here
git submodule update --init --recursive
- Setup config and install dependencies for ruby
bundle config set --local without 'development test'
bundle install
- Generate secret token
bundle exec rake generate_secret_token
- Migrate and load default data for db
set RAILS_ENV=production
bundle exec rake db:migrate
bundle exec rake redmine:load_default_data
bundle exec rake redmine:plugins:migrate NAME=redmine_dmsf
- Run server and nginx
start nginx
bundle exec rails server -u puma -e production