1
2

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.

Grav

Last updated at Posted at 2020-07-29

参考

起動

run.sh
docker run \
  --name=grav \
  --restart unless-stopped \
  -p 8080:80 \
  -e DUID=1000 \
  -e DGID=1000 \
  -v $(pwd)/grav/backup:/var/www/grav/backup
  -v $(pwd)/grav/logs:/var/www/grav/logs
  -v $(pwd)/grav/user:/var/www/grav/user
  dsavell/grav:admin
docker-compose.yml
web:
  image: dsavell/grav:admin
  container_name: grav
  restart: always
  volumes:
    - ./backup:/var/www/grav/backup
    - ./logs:/var/www/grav/logs
    - ./user:/var/www/grav/user
  ports:
    - 3000:80
  environment:
    - DUID=1000
    - DGID=1000

手動インストール

phpビルトインサーバーでの起動方法

apt install -y \
  php-curl

git clone "https://github.com/getgrav/grav.git"
cd grav
./bin/grav install
php -S localhost:8001 system/router.php

admin plugin

bin/gpm install admin

bin/plugin login new-user

plugins

apt install -y \
 sqlite \
 php-pdo \
 php-sqlite3

bin/gpm install tntsearch

mkdir -p user/config/plugins

cp user/plugins/tntsearch/tntsearch.yaml \
   user/config/plugins/tntsearch.yaml
クエリの動作確認
# index作成
bin/plugin tntsearch index

bin/plugin tntsearch query ipsum

mermaid

bin/gpm install mermaid-diagrams
書き方
[mermaid]
graph TB
sq[Square shape] --> ci((Circle shape))

subgraph A subgraph
    od>Odd shape]-- Two line<br>edge comment --> ro
    di{Diamond <br/> line break} -.-> ro(Rounded<br>square<br>shape)
    di==>ro2(Rounded square shape)
end

classDef green fill:#9f6,stroke:#333,stroke-width:2px;
classDef orange fill:#f96,stroke:#333,stroke-width:4px;
class sq,e green
class di orange
[/mermaid]

無題.png

マルチアカウント

/user/accounts/ユーザ名.yaml
password: 'password'
email: 'youremail@mail.com'
fullname: 'Taro Yamada'
title: 'Editor'
access:
  admin:
    login: 'true'
    pages: 'true'

wondercms

あとで試す。

  • phpの curl, zip が必要

1
2
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
1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?