Giter Club home page Giter Club logo

growi-docs's People

Contributors

aikahiyama avatar fezzlk avatar fujita-kazuki avatar hakumizuki avatar itizawa avatar izumips avatar kaishuu0123 avatar kaori-tokashiki avatar kouki-o avatar miya avatar mizozobu avatar moekumasaka avatar paramartha-grune avatar paramarthata avatar reiji-h avatar ryo-h15 avatar sakazuki avatar satof3 avatar shinoka7 avatar skomma avatar soumaeda avatar stevenfukase avatar tatsuyaise avatar tsuyoshisuzukief avatar utsushiiro avatar yasumichi avatar yohei-shiina avatar yukendev avatar yuki-takei avatar zahmis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

growi-docs's Issues

日英のリソース構成について

翻訳を試みようと思いましたが、全体の構成に疑問を持ったのでissueを発行させていただきます。

ディレクトリ構成について

GitHub上のリソースの構成を、以下のように変更するのはいかがでしょうか。

変更前構成

weseek/growi-docs
- docs
  + api
  + dev
  + guide
  - ja
    + dev
    + guide

変更後構成

weseek/growi-docs
- docs
  - en
    + dev
    + guide
    + api
    ...
  - ja
    + dev
    + guide
    + api
    ...

構成変更による影響

GitHub上の構成だけでなく、URLも以下のように変更されるかと考えていますが、日英だけでなく、複数言語対応するのであれば、都合も良いのではないかと考えています。

https://docs.growi.org/{locale}

つまり、現状では以下のように変更されると考えております。

以上となります。

CentOS の代わりに AlmaLinux へのインストール手順の追加

CentOS | GROWI Docsがしばらく更新されていませんが、CentOS プロジェクトが終了したこともあり、代替の AlmaLinux または Rocky Linux など、RedHat 系の Linux へのインストール手順を追加した方が良いと考えます。

Google トレンドで見る限り、AlmaLinux が優勢のようです。可能であれば、Ubuntu Server の更新内容も取り込みつつ、AlmaLinux へのインストール手順を作成したいと存じます。いかがでしょうか?

Please update this docs' Install section.

On the English Page, it says;

Overview

This chapter introduces the installation process for GROWI on CentOS 7. Installation on CentOS 6 has not been verified.

Software needed for Setup are listed below.

  • Node.js 14.x (DO NOT USE 14.x)
  • npm 6.x
  • yarn
  • MongoDB 4.x
  • (Optional) Elasticsearch 6.x
  • (Optional) systemd
  • (Optional) Apache or nginx

The above mentions Node.js 14.x, but the next section is as follows.

Installation for node.js 8.x & npm

But the sample code is

$ curl -sL https://rpm.nodesource.com/setup_14.x -o nodesource_setup.sh

This might confuse who tries to install.

I'm a Japanese, so I looked at the Install, and it says;

  • node.js 8.x (DO NOT USE 9.x)
  • npm 6.x
  • yarn
  • MongoDB 3.x
  • (Optional) Elasticsearch 5.x
  • (Optional) systemd
  • (Optional) Apache or nginx

Following the instructions and when I tried to install GROWI by running yarn, it failed and said;

$ yarn
yarn install v1.22.19
[1/5] Validating package.json...
error [email protected]: The engine "node" is incompatible with this module. Expected version "^14 || ^16". Got "8.17.0"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

I'm so disappointed. I need to start all over again... GROWI's reputations in Japan are the highest, so I decided to install it, but unable...

Please update the document.

「開発環境の構築」において、credential helper のパスが Git v2.36.1 未満のパスになっている

開発環境の構築」-「Git のインストール」-「設定」において、# Windows の場合は、WSL 内から更にホストPCの credential helper を参照する設定を行うのコマンドが、

git config --global credential.helper "/mnt/c/Program\ Files/Git/mingw64/bin/git-credential-manager-core.exe"

になっていますが、新しいバージョンの Git ではパスが異なっているようです。

インストールされている GIT が >= v2.39.0 の場合

git config --global credential.helper "/mnt/c/Program\ Files/Git/mingw64/bin/git-credential-manager.exe"

またはインストールされている GIT が >= v2.36.1 の場合

git config --global credential.helper "/mnt/c/Program\ Files/Git/mingw64/libexec/git-core/git-credential-manager.exe"

参考リンク

WSL で Git の使用を開始する | Microsoft Learn

GROWI独自形式のページリンクの説明をわかりやすくしてほしい

以下部分がよくわからなかったので、わかりやすく書いてほしい。

## GROWI 独自方式
書き方は、`[``]` のあいだに、パスを記載します。
`<`の後に配下ページを`/`をつけて記載します。
-
```markdown
[/Sandbox]
</user/admin1>
```

具体的に良くわからなかったのは、[ ]を使うリンクの書き方と、 < > を使うリンクの書き方の2パターンあるという事なのか、それともすべての説明で一つの書き方になっているのか、二行の関係性が良くわからないこと。

また一行目は「パス」という用語を、二行目は「配下ページ」を使っており、その意味の違いもよくわからなかった。
https://github.com/weseek/growi/blob/v5.0.10/packages/app/src/client/util/PreProcessor/Linker.js を読む限り、どちらも絶対パスが必要で、二行目は / が二つ以上必要というのが違いのようだが、それが読み取れなかった。

また合わせて、 https://github.com/weseek/growi-docs/pull/116/files#r417594067 に書かれているように、plugin-pukiwiki-like-linker によるリンクの書き方も書いてあると良い。

周辺ソフトウェアのバージョン要件が古い

インストール手順がGROWI 3.3以前の状態のようです。

Elasticsearch 5.x系を入れるという指示が書いてありますが、最新だと6.x系に変わっています。
しっかりと確認していませんが、Elasticsearch以外も古いままのようです。

NCHAN_URI環境変数のプロトコルはws://ではないか

箇所

## 環境変数の設定
### 簡易設定
```
S2SMSG_PUBSUB_SERVER_TYPE=nchan
NCHAN_URI=http://nchan
```

指摘

NCHAN_URI=http://nchan

ではなく

NCHAN_URI=ws://nchan

ではないか

理由

  • NCHAN_URI=http://nchanと設定した場合、(複数のGrowi動作時に必要な)設定が同期しない

Environment

Host

item version
OS Ubuntu 22.04.1 LTS
GROWI 5.1.0
node.js 16.16.0
npm 8.11.0
Using Docker yes
Using growi-docker-compose 部分的にyes(nchan検証用にカスタマイズ)

(Accessing https://{GROWI_HOST}/admin helps you to fill in above versions)

Client

item version
OS Ubuntu 22.04.1 LTS
browser Google Chrome 107.0.5304.110(Official Build) (64 ビット)

How to reproduce? (再現手順)

  1. docker-compose.yamlをnchan検証用に修正
  • nchanコンテナを追加
  • appの環境変数にNCHAN_URI=http://nchan, S2SMSG_PUBSUB_SERVER_TYPE=nchanを追加
  • appをもとに、nchan検証用としてapp_1(ポート3001でListen), app_2(ポート3002でListen)を立ち上げるように修正
version: '3'

services:
  app_1:
    build:
      context: .
      dockerfile: ./Dockerfile
    ports:
      - 127.0.0.1:3001:3000    # localhost only by default
    links:
      - mongo:mongo
      - elasticsearch:elasticsearch
      - nchan:nchan
    depends_on:
      - mongo
      - elasticsearch
      - nchan
    environment:
      - MONGO_URI=mongodb://mongo:27017/growi
      - ELASTICSEARCH_URI=http://elasticsearch:9200/growi
      - NCHAN_URI=http://nchan
      - S2SMSG_PUBSUB_SERVER_TYPE=nchan
      - PASSWORD_SEED=changeme
      - FILE_UPLOAD=mongodb   # activate this line if you use MongoDB GridFS rather than AWS
      # - FILE_UPLOAD=local     # activate this line if you use local storage of server rather than AWS
      # - MATHJAX=1             # activate this line if you want to use MathJax
      # - PLANTUML_URI=http://  # activate this line and specify if you use your own PlantUML server rather than public plantuml.com
      # - HACKMD_URI=http://    # activate this line and specify HackMD server URI which can be accessed from GROWI client browsers
      # - HACKMD_URI_FOR_SERVER=http://hackmd:3000  # activate this line and specify HackMD server URI which can be accessed from this server container
      # - FORCE_WIKI_MODE='public'    # activate this line to force wiki public mode
      # - FORCE_WIKI_MODE='private'   # activate this line to force wiki private mode

    entrypoint: "dockerize
                  -wait tcp://mongo:27017
                  -wait tcp://elasticsearch:9200
                  -wait tcp://nchan:80
                  -timeout 60s
                  /docker-entrypoint.sh"
    command: ["yarn migrate && node -r dotenv-flow/config --expose_gc dist/server/app.js"]

    restart: unless-stopped
    volumes:
      - app_data:/data

  app_2:
    build:
      context: .
      dockerfile: ./Dockerfile
    ports:
      - 127.0.0.1:3002:3000    # localhost only by default
    links:
      - mongo:mongo
      - elasticsearch:elasticsearch
      - nchan:nchan
    depends_on:
      - mongo
      - elasticsearch
      - nchan
    environment:
      - MONGO_URI=mongodb://mongo:27017/growi
      - ELASTICSEARCH_URI=http://elasticsearch:9200/growi
      - NCHAN_URI=http://nchan
      - S2SMSG_PUBSUB_SERVER_TYPE=nchan
      - PASSWORD_SEED=changeme
      - FILE_UPLOAD=mongodb   # activate this line if you use MongoDB GridFS rather than AWS
      # - FILE_UPLOAD=local     # activate this line if you use local storage of server rather than AWS
      # - MATHJAX=1             # activate this line if you want to use MathJax
      # - PLANTUML_URI=http://  # activate this line and specify if you use your own PlantUML server rather than public plantuml.com
      # - HACKMD_URI=http://    # activate this line and specify HackMD server URI which can be accessed from GROWI client browsers
      # - HACKMD_URI_FOR_SERVER=http://hackmd:3000  # activate this line and specify HackMD server URI which can be accessed from this server container
      # - FORCE_WIKI_MODE='public'    # activate this line to force wiki public mode
      # - FORCE_WIKI_MODE='private'   # activate this line to force wiki private mode

    entrypoint: "dockerize
                  -wait tcp://mongo:27017
                  -wait tcp://elasticsearch:9200
                  -wait tcp://nchan:80
                  -timeout 60s
                  /docker-entrypoint.sh"
    command: ["yarn migrate && node -r dotenv-flow/config --expose_gc dist/server/app.js"]

    restart: unless-stopped
    volumes:
      - app_data:/data

  nchan:
    image: weseek/nginx-nchan:latest
    ports:
      - 8080:80

  mongo:
    image: mongo:4.4
    restart: unless-stopped
    volumes:
      - mongo_configdb:/data/configdb
      - mongo_db:/data/db

  elasticsearch:
    build:
      context: ./elasticsearch
      dockerfile: ./Dockerfile
    environment:
      - bootstrap.memory_lock=true
      - "ES_JAVA_OPTS=-Xms256m -Xmx256m"  # increase amount if you have enough memory
      - LOG4J_FORMAT_MSG_NO_LOOKUPS=true # CVE-2021-44228 mitigation for Elasticsearch <= 6.8.20/7.16.0
    ulimits:
      memlock:
        soft: -1
        hard: -1
    restart: unless-stopped
    volumes:
      - es_data:/usr/share/elasticsearch/data
      - ./elasticsearch/config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml

volumes:
  app_data:
  mongo_configdb:
  mongo_db:
  es_data:
  1. docker-compose起動
docker-compose up
  1. localhost:3001(app_1)にブラウザでアクセスし、ユーザー作成を済ましたあと、アプリ設定画面から設定(サイト名など)を変更する
  2. localhost:3002(app_2)にアクセスし、アプリ設定画面から設定を確認する

What happens? (症状)

  • localhost:3002(app_2)の設定画面上で、localhost:3001(app_1)で行った変更が反映されていない

docker-compose起動時

app_1_1          | {"name":"growi","hostname":"e6d9cd7f0d4b","pid":17,"level":50,"msg":"Unhandled Rejection: Promise: Promise {\n  <rejected> SyntaxError: The URL's protocol must be one of \"ws:\", \"wss:\", or \"ws+unix:\"\n      at initAsClient (/opt/growi/node_modules/ws/lib/websocket.js:688:17)\n      at new WebSocket (/opt/growi/node_modules/ws/lib/websocket.js:84:7)\n      at /opt/growi/node_modules/reconnecting-websocket/dist/reconnecting-websocket-cjs.js:519:19\n      at runNextTicks (node:internal/process/task_queues:61:5)\n      at processTimers (node:internal/timers:499:9)\n} Reason: SyntaxError: The URL's protocol must be one of \"ws:\", \"wss:\", or \"ws+unix:\"\n    at initAsClient (/opt/growi/node_modules/ws/lib/websocket.js:688:17)\n    at new WebSocket (/opt/growi/node_modules/ws/lib/websocket.js:84:7)\n    at /opt/growi/node_modules/reconnecting-websocket/dist/reconnecting-websocket-cjs.js:519:19\n    at runNextTicks (node:internal/process/task_queues:61:5)\n    at processTimers (node:internal/timers:499:9)","time":"2022-11-13T13:22:27.497Z","v":0}

app_2で設定画面を表示したとき

app_2_1          | {"name":"growi:service:s2s-messaging:nchan","hostname":"addf8f957f30","pid":19,"level":30,"msg":"The connection to config pubsub server is offline. Try to reconnect...","time":"2022-11-13T13:24:13.430Z","v":0}

What is the expected result? (期待される動作)

  • 設定の変更が、nchanを通じて複数のGrowiで同期される

解決方法

Growi起動時のエラーにおいて

SyntaxError: The URL's protocol must be one of \"ws:\", \"wss:\", or \"ws+unix:\"

とある通り、NCHAN_URIのプロトコルはws:, wss:, または ws+unix:でないと動作しないと思われる
よって、冒頭で述べたとおり

NCHAN_URI=ws://nchan

とすることで解決できました

GROWI Developers Wikiによると
GROWI は nchanから設定変更を subscribeする際、WebSocketを用いるようなので
URIのプロトコルはws://である必要があると思われます

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.