docker容器redmine安装和卸载插件
今天给大家说下怎么在docker容器redmine里进行安装和卸载插件,这里说的redmine是2.x和之后的版本,之前的版本没有测试过,所以低于这个版本的请略过.
系统:centos 6.5(64位)
软件版本:redmine 2.5.3
redmine_ckeditor 1.0.20
docker 1.7.1
1.启动redmine
docker怎么启动redmine,这里就不说了,毕竟连容器都无法启动的话,看这篇文章也没用.
2.把插件拷进docker里
wget https://github.com/a-ono/redmine_ckeditor/archive/1.0.20.zip
unzip 1.0.20.zip
mv redmine_ckeditor-1.0.20 redmine_ckeditor
cp -R redmine_ckeditor /var/lib/docker/devicemapper/mnt/394bb2dec6a5941e204c9462ca58d5df49ed7a1e1a0c03809f01e9465281b4ec/rootfs/home/redmine/redmine/plugins/
3.安装插件
docker exec -it redmine bash
cd home/redmine/redmine
apt-get update
apt-get install imagemagick -y
bundle install --without development test
bundle exec rake redmine:plugins:migrate RAILS_ENV=production
如果上面步骤没有问题的话,那你就可以重启redmine了,有问题的话,请根据提示自己解决.
4.卸载插件
bundle exec rake redmine:plugins:migrate NAME=redmine_ckeditor VERSION=0 RAILS_ENV=production
ps:
注意插件名称就是插件目录名称
然后删除plugins目录下的redmine_ckeditor文件夹,当然你也可以不删除移走也行.最后再重启redmine就完成卸载插件了.
好了,到这里就完成了redmine插件的安装和卸载.
系统:centos 6.5(64位)
软件版本:redmine 2.5.3
redmine_ckeditor 1.0.20
docker 1.7.1
1.启动redmine
docker怎么启动redmine,这里就不说了,毕竟连容器都无法启动的话,看这篇文章也没用.
2.把插件拷进docker里
wget https://github.com/a-ono/redmine_ckeditor/archive/1.0.20.zip
unzip 1.0.20.zip
mv redmine_ckeditor-1.0.20 redmine_ckeditor
cp -R redmine_ckeditor /var/lib/docker/devicemapper/mnt/394bb2dec6a5941e204c9462ca58d5df49ed7a1e1a0c03809f01e9465281b4ec/rootfs/home/redmine/redmine/plugins/
3.安装插件
docker exec -it redmine bash
cd home/redmine/redmine
apt-get update
apt-get install imagemagick -y
bundle install --without development test
bundle exec rake redmine:plugins:migrate RAILS_ENV=production
如果上面步骤没有问题的话,那你就可以重启redmine了,有问题的话,请根据提示自己解决.
4.卸载插件
bundle exec rake redmine:plugins:migrate NAME=redmine_ckeditor VERSION=0 RAILS_ENV=production
ps:
注意插件名称就是插件目录名称
然后删除plugins目录下的redmine_ckeditor文件夹,当然你也可以不删除移走也行.最后再重启redmine就完成卸载插件了.
好了,到这里就完成了redmine插件的安装和卸载.
评论: