顯示具有 Redmine 標籤的文章。 顯示所有文章
顯示具有 Redmine 標籤的文章。 顯示所有文章

2022年4月15日 星期五

[Docker][Redmine 5.0] How to use docker to use redmine

Pull docker image first.
docker pull sameersbn/redmine:5.0.0

Download “docker-compose-sqlite3.yml”:https://github.com/sameersbn/docker-redmine/blob/master/docker-compose-sqlite3.yml

Following command will start redmine by using docker
sudo docker-compose up

Following command can login into above container
docker exec -it “Container” /bin/bash


How to reset the docker

This command will let docker down
sudo docker-compose down

Re-create a clear contain
sudo docker-compose up -d

Start docker again
sudo docker-compose up


Restart the web server inside the container

Following command can login into above container
docker exec -it “Container” /bin/bash

Following command will restart web server
sudo service nginx restart

Ref
https://quicknotepadtutorial.blogspot.com/2020/07/setting-up-redmine-with-docker-compose.html

https://github.com/sameersbn/docker-gitlab

 

2020年10月26日 星期一

[redmine][bitnami] How to virtualbox to build redmine quickly

  1. Download ova (virtualbox image) from bitnami webpage
  2. Start ova at virtualbox
  3. INSTALL SQLITE3 GEM FOR RUBY
    gem install sqlite3-ruby
  4. disable bundle deployment mode.
    bundle install --no-deployment
  5. Start to configure the environment settings.
    5-1. Set sqlite database
    cd REDMINE
    CONFIGURE DATABASE
    echo “production:” > config/database.yml &&
    echo " adapter: sqlite3" >> config/database.yml &&
    echo " database: db/redmine.sqlite3" >> config/database.yml
    5-2. POPULATE DATABASE
    cd REDMINE
    rake db:migrate RAILS_ENV=“production”
    rake redmine:load_default_data RAILS_ENV=“production”
    5-3. Create secret_token
    cd REDMINE
    echo “production:” > config/secrets.yml
    echo " secret_key_base: $(rake secret)" >> config/secrets.yml
  6. Change the permission of folder of redmine
    chmod 777 /home/bitnami/apps/redmine -Rf
  7. Restart redmine again
    /home/bitnami/stack
    ./ctlscript.sh restart

2017年7月20日 星期四

[Redmine][bitnami] How to quick install redmine

Download bitnami - redmine from bitnami - redmine

Change the permission of bitnami-redmine-3.4.2-0-linux-x64-installer.run
chmod 755 bitnami-redmine-3.4.2-0-linux-x64-installer.run

Install bitnami redmine
./bitnami-redmine-3.4.2-0-linux-x64-installer.run --disable_glibcxx_version_check 1


INSTALL SQLITE3 GEM FOR RUBY
/home/happy/webs/redmine-work1/ruby/bin/gem install sqlite3-ruby

Jump to redmine folder
cd /home/happy/webs/redmine-work1/apps/redmine/htdocs
Install the dependencies specified in your Gemfile
Please stay at above folder example, and type following command.
Please modify the string of "/home/happy/webs/redmine-work1" to your real command folder.
/home/happy/webs/redmine-work1/ruby/bin/bundle install --no-deployment

Start to configure the environment settings.
cd /home/happy/webs/redmine-work1/apps/redmine/htdocs
CONFIGURE DATABASE
echo “production:” > config/database.yml &&\
echo ” adapter: sqlite3” >> config/database.yml &&\
echo ” database: db/redmine.sqlite3” >> config/database.yml

POPULATE DATABASE
cd /home/happy/webs/redmine-work1/apps/redmine/htdocs
/home/happy/webs/redmine-work1/ruby/bin/rake db:migrate RAILS_ENV=”production”
/home/happy/webs/redmine-work1/ruby/bin/rake redmine:load_default_data RAILS_ENV=”production”

Create secret_token
cd /home/happy/webs/redmine-work1/apps/redmine/htdocs
echo “production:” > config/secrets.yml &&\
echo ” secret_key_base: $(/home/happy/webs/redmine-work1/ruby/bin/rake secret)” >> config/secrets.yml

Restart the server
cd /home/happy/webs/redmine-work1
bash ctlscript.sh restart

Reference:


How to Modify the port of mysql

Modify the port of mysql
vim ./apache2/conf/bitnami/bitnami.conf +35
modify all 8443 to other port number

Modify the port of http
vim ./apache2/conf/bitnami/bitnami.conf +35
modify all 8081 to other port number

Question:
$ gem install sqlite3
ERROR: Could not find a valid gem ‘sqlite3’ (>= 0), here is why:
Unable to download data from https://rubygems.org/ - SSL_connect returned=1 errno=0 state=error: certificate verify failed (https://api.rubygems.org/latest_specs.4.8.gz)

Answer:
$ gem sources --remove https://rubygems.org/
https://rubygems.org/ removed from sources

$gem sources -a http://rubygems.org/
https://rubygems.org is recommended for security over http://rubygems.org/

Ref:

2017年2月21日 星期二

2016年11月15日 星期二

[Apache][Archlinux] Remind can use apache to browser

 Apache
+-----------------------------------------------+
|                                               |
|                                               |
|                                               |
|                                               |
|        Load Passenger module                  |
|       +-----------------------------+         |
|       | 1. where is passenger       |         |
|       | 2. where is ruby (bin file) |         |
|       |                             |         |
|       +-----------------------------+         |
|                                               |
+-----------------------------------------------+


Please install gcc zlibc curl make first

Install passenger - A fast and robust web server and application server for Ruby
gem install passenger


Install Apache Passenger module
$ passenger-install-apache2-module



Create new configuration file for including into apache configuration file.
vim /etc/httpd/conf/redmine.conf
LoadModule passenger_module /home/freeman/APP/RUBY/lib/ruby/gems/2.3.0/gems/passenger-5.0.30/buildout/apache2/mod_passenger.so
<IfModule mod_passenger.c>

# passenger location
    PassengerRoot /home/freeman/APP/RUBY/lib/ruby/gems/2.3.0/gems/passenger-5.0.30  

# ruby bin file

    PassengerRuby /home/freeman/APP/RUBY/bin/ruby     
</IfModule>

NameVirtualHost *:8080

<VirtualHost *:8080>

# If root fold different, this row need to change
  DocumentRoot /home/freeman/webs/redmine-work/public  
  RailsEnv production
  ErrorLog /var/log/httpd/rails_error_log
  CustomLog /var/log/httpd/rails_access_log common
</VirtualHost>



NameVirtualHost *:8090

<VirtualHost *:8090>

# If root fold different, this row need to change
  DocumentRoot /home/freeman/webs/Learning/public
  RailsEnv production
  ErrorLog /var/log/httpd/rails_error_log
  CustomLog /var/log/httpd/rails_access_log common
</VirtualHost> 


vim /etc/httpd/conf/httpd.conf
Add following code into httpd.conf
# Open two port at apache
Listen 80
Listen 8080
Listen 8090
# Include ruby settings
Include conf/redmine.conf


Start apache
sudo systemctl start httpd


Reference:

Q:
An error occurred on the page you were trying to access

A:
cd redmine
chmod -R 755 files log tmp public/plugin_assets

systemctl restart httpd

Reference:

2016年11月14日 星期一

2016年11月7日 星期一