0
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Dockerを用いたプロジェクト管理ツール OpenProject 環境構築方法 メモ

Posted at
  • プロジェクト管理ツール**OpenProject**をDockerを利用して構築する方法についてメモする。
  • DBには、個人的に使い慣れたMySQLを使用する。

構築準備

フォルダ構成

root_project - docker-compose.yml
			|_ db 	-- openproject
					|_ my.cnf

設定ファイル

docker-compose.yml

  • OpenProject用コンテナとDBコンテナ(MySQL5.7)を立ち上げる。
version: "3"

services:
  openproject:
    container_name: openproject
    image: openproject/community:7.4.3
    depends_on:
      - mysql
    environment:
      - DATABASE_URL=mysql2://mysqluser:mysqlpass@openprojectdb:3307/openprojectdb
      - SECRET_KEY_BASE=openproject_secret_key
    volumes:
      - ./db/openproject/static:/var/db/openproject
    ports:
      - 8090:80
    restart: always
  mysql:
    image: mysql:5.7
    container_name: openprojectdb
    environment:
      MYSQL_ROOT_PASSWORD: rootpass
      MYSQL_DATABASE: openprojectdb
      MYSQL_USER: mysqluser
      MYSQL_PASSWORD: mysqlpass
    volumes:
      - ./db/openproject/mysql:/var/lib/mysql
      - ./db/my.cnf:/etc/mysql/conf.d/my.cnf
    restart: always
    ports:
      - 3307:3307
    command: --port 3307

my.cnf

  • DBの文字コード設定
[mysqld]   
character-set-server=utf8mb4
collation-server=utf8mb4_unicode_ci

[client]
default-character-set=utf8mb4

動作確認

  • コンテナ起動

    docker-compose up -d
    
  • アクセス

  • その他

    • 適宜、言語設定などを変更する。

参考情報

0
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?