Top Menu

Jump to content
Home
    • Projects
    • Work packages
    • News
    • Getting started
    • Introduction video
      Welcome to OpenProject Community
      Get a quick overview of project management and team collaboration with OpenProject. You can restart this video from the help menu.

    • Help and support
    • User guides
    • Videos
    • Shortcuts
    • Community forum
    • Professional support

    • Additional resources
    • Data privacy and security policy
    • Digital accessibility (DE)
    • OpenProject website
    • Security alerts / Newsletter
    • OpenProject blog
    • Release notes
    • Report a bug
    • Development roadmap
    • Add and edit translations
    • API documentation
  • Sign in
      Forgot your password?
      Create a new account

      or sign in with your existing account

      Google

Side Menu

  • Overview
  • Activity
  • Roadmap
  • Work packages
  • Calendars
  • Team planners
  • Boards
  • Forums
  • Wiki
    • Table of contents
      • Expanded. Click to collapseCollapsed. Click to showDeveloper
        • Hierarchy leafAccessibility Checklist
        • Hierarchy leafCode Review Guidelines
        • Expanded. Click to collapseCollapsed. Click to showContribution
          • Hierarchy leafGit Workflow
          • Hierarchy leafTranslations
        • Expanded. Click to collapseCollapsed. Click to showDeveloping Plugins
          • Hierarchy leafDeveloping an OmniAuth Authentication Plugin
        • Hierarchy leafRelease Process
        • Hierarchy leafReport a bug
        • Hierarchy leafSecurity
        • Hierarchy leafSetting up an OpenLDAP server for testing
        • Hierarchy leafTheme Features
      • Hierarchy leafDownload
      • Expanded. Click to collapseCollapsed. Click to showFeature tour
        • Hierarchy leafRelease Notes OpenProject 30
        • Expanded. Click to collapseCollapsed. Click to showRelease Notes OpenProject 30 - Overview
          • Hierarchy leafGlossary
          • Hierarchy leafRelease Notes - Accessibility
          • Hierarchy leafRelease Notes - Accessibility changes
          • Hierarchy leafRelease Notes - Add work package queries as menu items to sidebar
          • Hierarchy leafRelease Notes - Copy projects based on Templates
          • Hierarchy leafRelease Notes - Design changes
          • Hierarchy leafRelease Notes - Fixed Bugs
          • Hierarchy leafRelease Notes - Keyboard Shortcuts
          • Hierarchy leafRelease Notes - Project settings
          • Hierarchy leafRelease Notes - Ruby&Rails Update
          • Hierarchy leafRelease Notes - Security
          • Hierarchy leafRelease Notes - Timelines
          • Hierarchy leafRelease Notes - Work packages
      • Hierarchy leafHowto create animated gifs
      • Hierarchy leafMigration Squashing
      • Hierarchy leafMod security
      • Hierarchy leafNew work package page
      • Hierarchy leafOP3 to OP4 Debian upgrade
      • Hierarchy leafOP4 Ubuntu1404 Stable with MySQL in production
      • Hierarchy leafOpenProject 40 Development Setup
      • Expanded. Click to collapseCollapsed. Click to showOpenProject Foundation
        • Hierarchy leafBoards
        • Hierarchy leafMembers
        • Hierarchy leafOPF-Meetings
        • Hierarchy leafStatutes
      • Expanded. Click to collapseCollapsed. Click to showRelease Notes
        • Hierarchy leafOpenProject released on Bitnami
      • Expanded. Click to collapseCollapsed. Click to showRelease Notes OpenProject 40 - Overview
        • Hierarchy leafRelease Notes OpenProject 40 - Accessibility improvements
        • Hierarchy leafRelease Notes OpenProject 40 - Column header functions in work package table
        • Hierarchy leafRelease Notes OpenProject 40 - Improved Design
        • Hierarchy leafRelease Notes OpenProject 40 - Integrated query title on work package page
        • Hierarchy leafRelease Notes OpenProject 40 - Integrated toolbar on work package page
        • Hierarchy leafRelease Notes OpenProject 40 - OmniAuth integration for OpenProject
        • Hierarchy leafRelease Notes OpenProject 40 - Work package details pane
      • Expanded. Click to collapseCollapsed. Click to showSecurity and privacy
        • Hierarchy leafFAQ
      • Expanded. Click to collapseCollapsed. Click to showSupport
        • Expanded. Click to collapseCollapsed. Click to showDownload and Installation
          • Hierarchy leafInstallation MacOS
          • Expanded. Click to collapseCollapsed. Click to showInstallation OpenProject 3 0
            • Hierarchy leafDebian Stable with MySQL in production
            • Hierarchy leafInstallation Ubuntu
            • Hierarchy leafInstallation Windows
            • Hierarchy leafInstallation on Centos 65 x64 with Apache and PostgreSQL 93
          • Expanded. Click to collapseCollapsed. Click to showInstallation OpenProject 40
            • Hierarchy leafOP4 Debian Stable with MySQL in production
          • Expanded. Click to collapseCollapsed. Click to showMigration paths
            • Hierarchy leafFrom Chilliproject to OpenProject
            • Hierarchy leafMigration 15 to 30
            • Hierarchy leafMigration 24 to 30
            • Hierarchy leafMigration Redmine 2x › OpenProject 30
            • Hierarchy leafOpenProject 3 Migration
          • Hierarchy leafOpenProject 40
        • Expanded. Click to collapseCollapsed. Click to showNews
          • Hierarchy leafNew OpenProject Translations Plugin
          • Hierarchy leafNew Plugin on OpenProjectorg Local Avatars
          • Hierarchy leafNew design for OpenProject
          • Hierarchy leafNews Accessibility workshop for OpenProject
          • Hierarchy leafNews Glossary for OpenProject
          • Hierarchy leafNews Heartbleed fixed
          • Hierarchy leafNews Icon Fonts
          • Hierarchy leafNews OpenProject 30 Release
          • Hierarchy leafNews Release GitHub Integration Plugin
          • Hierarchy leafNews Success Story Deutsche Telekom
          • Hierarchy leafNews Timelines
          • Hierarchy leafOpenProject 3013 released
          • Hierarchy leafOpenProject 3017 released
          • Hierarchy leafOpenProject 40 released
          • Hierarchy leafOpenProject 40 will be coming soon
          • Hierarchy leafOpenProject 405 released
          • Hierarchy leafOpenProject and pkgrio
          • Hierarchy leafOpenProject news moved to a new blog
          • Hierarchy leafOpenProjectBitnami
          • Hierarchy leafPackager version with plugins released ("Community edition")
          • Hierarchy leafRegistration OpenProject-Foundation
          • Hierarchy leafRelease OpenProject AuthPlugins
          • Hierarchy leafUpdates on OpenProject
          • Hierarchy leafWe need your feedback for the the new fullscreen view for work packages
        • Hierarchy leafOpenProject Plug-Ins
      • Expanded. Click to collapseCollapsed. Click to showWiki
        • Hierarchy leaf2nd Level Support
You are here:
  • Forums
  • Plugins

Content

Install a custom plugin to a docker compose container

Added by Frédéric MAZUR 20 days ago

Hello all,

I want to install a custom plugin on a openproject based on a "docker compose" installation, but I don't find how to do this inside the openproject documentation.

Here is the plugin that I want to install : https://github.com/btey/openproject-gitlab-integration

And I follow the documentation here :  https://www.openproject.org/docs/installation-and-operations/installation/docker/#openproject-plugins

I did not understand If I was able to modify the current "docker compose" installation of my openproject instance to add a plugin or if I have to create a new docker image myself , and integrate manually the openproject version, the postgresql image and my plugin ( and any other plugins that I could test ). I am not familiar with docker , all that I have done is install openproject with the documentation that explain the "docker compose" method

Part to get deployment from repository

  • git clone https://github.com/opf/openproject-deploy --depth=1 --branch=stable/12 openproject

Part to install a more recent docker version ( I am using debian 10 linux ):

  • apt install ca-certificates curl gnupg lsb-release
  • mkdir -m 0755 -p /etc/apt/keyrings
  • curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
  • echo   "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian  $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
  • apt update
  • apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

And then, just install and run with :

  • docker compose pull
  • OPENPROJECT_HTTPS=false OPENPROJECT_HOST__NAME=xxx.xxx.com:8080 docker compose up -d

What is the best way to add a plugin on my current "docker compose" based installation ?

Best regards,

F. MAZUR.


Replies (2)

RE: Install a custom plugin to a docker compose container - Added by Markus Kahl 20 days ago

Hey,

to use your own plugin you will have to adjust the docker-compose file. Specifically these two lines.
You can change the definition so that your own image is built as seen in the docker docs.

So in your case you might want to change these lines to:

x-op-image: &image
  image: my-openproject-with-gitlab
  build:
    context: gitlab-integration

Where gitlab-integration would be a folder containing the Gemfile.plugins which should look something like this:

group :opf_plugins do
  gem "openproject-gitlab", git: "https://github.com/btey/openproject-gitlab-integration.git", branch: "master"
end

And the Dockerfile which should look as described in our docs too. That is like the following.

FROM openproject/community:12

# If installing a local plugin (using `path:` in the `Gemfile.plugins` above),
# you will have to copy the plugin code into the container here and use the
# path inside of the container. Say for `/app/vendor/plugins/openproject-slack`:
# COPY /path/to/my/local/openproject-slack /app/vendor/plugins/openproject-slack

COPY Gemfile.plugins /app/

# If the plugin uses any external NPM dependencies you have to install them here.
# RUN npm add npm <package-name>*

RUN bundle config unset deployment && bundle install && bundle config set deployment 'true'
RUN ./docker/prod/setup/postinstall.sh

In the docs for the plugin it says you have to use bundle install --deployment --without mysql2 sqlite development test therubyracer docker so you may have to do that instead of a simple bundle install in the second to last line of the Dockerfile.

RE: Install a custom plugin to a docker compose container - Added by Frédéric MAZUR 15 days ago

Hello,

Thank you for your answer. 

I was able to add the custom plugin with your help, I have just kept "image: openproject/community:${TAG:-12}" because with my-openproject-with-gitlab it did not work ( I guess that I should do a fork of the openproject, I prefer keep the original path , I have no modification, I just wanted to add a plugin ).

I needed to rebuild with docker compose build and I was a little bit afraid because it took 10min , and I saw that it recreated the database, I was wondering that I will have lost all the data inside database. But no, all has been kept, I just have to restart ( docker compose stop / docker compose up -d ) to see that the plugin is now available.

Now I have to see how to use this plugin, it is not exactly what I expected... Another question, now I have this plugin, what happens if I export the database with the backup feature, and I reimport on a fresh install without the plugin ? Will it work ? I am afraid it won't

I see that the gitlab integration is in the roadmap : https://community.openproject.org/projects/openproject/work_packages/23673/activity ( version 13.1.0 ) maybe I better should wait ?

Regards,

  • (1 - 2/2)
Loading...