1、新建目录directus
2、新建uploads 更新目录权限777
3、新建docker-compose.yml
内容才参考如下
version: '3'
services:
directus:
image: directus/directus:latest
ports:
- 8055:8055
volumes:
# - ./database:/directus/database
- ./uploads:/directus/uploads
environment:
KEY: '123456'
SECRET: '123456'
ADMIN_EMAIL: '管理员邮箱'
ADMIN_PASSWORD: '登录密码'
DB_CLIENT: 'mysql'
DB_HOST: '127.0.0.1'
DB_PORT: '3306'
DB_DATABASE: 'directus'
DB_USER: 'directus'
DB_PASSWORD: 'directus'
WEBSOCKETS_ENABLED: true
4、执行命令docker-compose up -d 启动服务
5、访问地址:127.0.0.1:8055 ,输入配置文件中配置的用户名密码登录