1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

リバースプロキシ×Nextcloudの環境構築のために必要なこと

Last updated at Posted at 2024-11-27

環境変数として以下の4つを追加で設定する。

OVERWRITEPROTOCOL=
OVERWRITEHOST=
OVERWRITEWEBROOT=
OVERWRITECLIURL=
TRUSTEDPROXIES=
dokcer-compose.ymlの例
services:
  db:
    container_name: nextcloud-db-container
    image: postgres:16.2
    env_file:
      - .env
    expose:
      - "5432"
    volumes:
      - db_data:/var/lib/postgresql/data
      - ./database/postgresql.conf:/etc/postgresql/postgresql.conf
    command: -c 'config_file=/etc/postgresql/postgresql.conf'
    restart: always

  app:
    image: nextcloud
    env_file:
      - .env
    ports:
      - ${NEXTCLOUD_PORT}:80
    links:
      - db
    volumes:
      - nextcloud:/var/www/html
    restart: always
    depends_on:
      - db

volumes:
  db_data:
  nextcloud:

.envファイルの例
# postgresql(docker)
POSTGRES_DB=
POSTGRES_USER=
POSTGRES_PASSWORD=
POSTGRES_HOST=
TZ=

# nextcloud(docker)
NEXTCLOUD_PORT=
NEXTCLOUD_ADMIN_USER=
NEXTCLOUD_ADMIN_PASSWORD=

# nextcloud
NEXTCLOUD_TRUSTED_DOMAINS=
OVERWRITEPROTOCOL=
OVERWRITEHOST=
OVERWRITEWEBROOT=
OVERWRITECLIURL=
TRUSTEDPROXIES=

参考↓

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

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?