Reorganize files
This commit is contained in:
13
.example.env
Normal file
13
.example.env
Normal file
@@ -0,0 +1,13 @@
|
||||
OPENPROJECT_TAG=16-slim
|
||||
OPENPROJECT_HTTPS=true
|
||||
OPENPROJECT_HOST__NAME=openproject.tvcloud.fr
|
||||
OPENPROJECT_HSTS=true
|
||||
RAILS_CACHE_STORE=memcache
|
||||
OPENPROJECT_CACHE__MEMCACHE__SERVER=openproject-cache:11211
|
||||
DATABASE_URL=postgres://postgres:pswd@openproject-db/openproject?pool=20&encoding=unicode&reconnect=true
|
||||
RAILS_MIN_THREADS=4
|
||||
RAILS_MAX_THREADS=16
|
||||
# set to true to enable the email receiving feature. See ./docker/cron for more options
|
||||
IMAP_ENABLED=false
|
||||
OPENPROJECT=openproject
|
||||
OPENPROJECT_DB=openproject-db
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1,2 +1,4 @@
|
||||
server.crt
|
||||
server.key
|
||||
.env
|
||||
services/nextcloud/db.env
|
||||
|
||||
4
.gitmodules
vendored
4
.gitmodules
vendored
@@ -1,4 +0,0 @@
|
||||
[submodule "openproject"]
|
||||
path = openproject
|
||||
url = https://github.com/opf/openproject-docker-compose.git
|
||||
branch = stable/16
|
||||
|
||||
7
configure.bash
Executable file
7
configure.bash
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
usage="Usage: $0 server_name project_root"
|
||||
server_name="${1:?$usage}"
|
||||
root="${2:?$usage}"
|
||||
sed -Ei "s/(^[[:blank:]]*server_name [^_][^.]*\.)[^;]*/\1${server_name}/" "$root"/services/nginx/default.conf
|
||||
sed -Ei "s/(^OPENPROJECT_HOST__NAME=[^.]*\.).*/\1${server_name}/" "$root"/.env
|
||||
@@ -15,27 +15,29 @@ volumes:
|
||||
x-op-restart-policy: &restart_policy
|
||||
restart: unless-stopped
|
||||
x-op-image: &image
|
||||
image: openproject/openproject:16-slim
|
||||
image: openproject/openproject:${OPENPROJECT_TAG}
|
||||
x-op-app: &app
|
||||
<<: [*image, *restart_policy]
|
||||
environment:
|
||||
OPENPROJECT_HTTPS: "true"
|
||||
OPENPROJECT_HOST__NAME: "openproject.tvcloud.fr"
|
||||
OPENPROJECT_HSTS: "true"
|
||||
RAILS_CACHE_STORE: "memcache"
|
||||
OPENPROJECT_CACHE__MEMCACHE__SERVER: "openproject-cache:11211"
|
||||
DATABASE_URL: "postgres://postgres:pswd@openproject-db/openproject?pool=20&encoding=unicode&reconnect=true"
|
||||
OPENPROJECT_HTTPS: "${OPENPROJECT_HTTPS}"
|
||||
OPENPROJECT_HOST__NAME: "${OPENPROJECT_HOST__NAME}"
|
||||
OPENPROJECT_HSTS: "${OPENPROJECT_HSTS}"
|
||||
RAILS_CACHE_STORE: "${RAILS_CACHE_STORE}"
|
||||
OPENPROJECT_CACHE__MEMCACHE__SERVER: "${OPENPROJECT_CACHE__MEMCACHE__SERVER}"
|
||||
DATABASE_URL: "${DATABASE_URL}"
|
||||
RAILS_MIN_THREADS: 4
|
||||
RAILS_MAX_THREADS: 16
|
||||
# set to true to enable the email receiving feature. See ./docker/cron for more options
|
||||
IMAP_ENABLED: "false"
|
||||
IMAP_ENABLED: "${IMAP_ENABLED}"
|
||||
OPENPROJECT: "${OPENPROJECT}"
|
||||
OPENPROJECT_DB: "${OPENPROJECT_DB}"
|
||||
volumes:
|
||||
- "openproject:/var/openproject/assets"
|
||||
- "${OPENPROJECT}:/var/openproject/assets"
|
||||
|
||||
services:
|
||||
proxy:
|
||||
build:
|
||||
dockerfile: ./nginx.Dockerfile
|
||||
context: ./services/nginx
|
||||
networks:
|
||||
- nextcloud-frontend
|
||||
- openproject-frontend
|
||||
@@ -51,10 +53,11 @@ services:
|
||||
|
||||
nextcloud:
|
||||
image: nextcloud:31-fpm
|
||||
env_file:
|
||||
- nextcloud-db.env
|
||||
environment:
|
||||
- MYSQL_HOST=nextcloud-db
|
||||
- MYSQL_PASSWORD=pswd
|
||||
- MYSQL_DATABASE=nextcloud
|
||||
- MYSQL_USER=nextcloud
|
||||
networks:
|
||||
- nextcloud-frontend
|
||||
- nextcloud-backend
|
||||
@@ -66,8 +69,6 @@ services:
|
||||
nextcloud-db:
|
||||
image: mariadb:11-ubi
|
||||
command: --transaction-isolation=READ-COMMITTED --log-bin=binlog --binlog-format=ROW
|
||||
env_file:
|
||||
- nextcloud-db.env
|
||||
environment:
|
||||
- MARIADB_ROOT_PASSWORD=pswd
|
||||
- MARIADB_AUTO_UPGRADE=1
|
||||
@@ -103,7 +104,7 @@ services:
|
||||
<<: *restart_policy
|
||||
stop_grace_period: "3s"
|
||||
volumes:
|
||||
- "openproject-db:/var/lib/postgresql/data"
|
||||
- "${OPENPROJECT_DB}:/var/lib/postgresql/data"
|
||||
environment:
|
||||
POSTGRES_PASSWORD: pswd
|
||||
POSTGRES_DB: openproject
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
MYSQL_PASSWORD=pswd
|
||||
MYSQL_DATABASE=nextcloud
|
||||
MYSQL_USER=nextcloud
|
||||
@@ -1,3 +0,0 @@
|
||||
MYSQL_PASSWORD=pswd
|
||||
MYSQL_DATABASE=nextcloud
|
||||
MYSQL_USER=nextcloud
|
||||
Submodule openproject deleted from 6831d93c1b
27
readme.md
27
readme.md
@@ -6,29 +6,38 @@ This project is a personal cloud of services:
|
||||
|
||||
# Setup
|
||||
|
||||
1. Generate a self-signed certificate.
|
||||
1. Generate a self-signed certificate for the proxy.
|
||||
|
||||
```
|
||||
openssl genpkey -algorithm RSA -out server.key
|
||||
openssl req -new -x509 -key server.key -out server.crt -days 365
|
||||
```
|
||||
|
||||
2. Make a `nextcloud-db.env` file. See `nextcloud-db.example.env`.
|
||||
2. Make a `.env` file for `docker-compose.yaml`. See `.example.env`.
|
||||
|
||||
3. Start the services.
|
||||
3. Configure the host name.
|
||||
|
||||
```
|
||||
docker compose up -d
|
||||
./configure.bash HOSTNAME .
|
||||
```
|
||||
|
||||
# Update/install Joplin
|
||||
4. Start the services.
|
||||
|
||||
```
|
||||
sudo docker compose up --detach
|
||||
```
|
||||
|
||||
# OpenProject
|
||||
|
||||
- [Upgrade](https://www.openproject.org/docs/installation-and-operations/installation/docker-compose/#upgrade)
|
||||
- [Backup](https://www.openproject.org/docs/installation-and-operations/installation/docker-compose/#backup)
|
||||
|
||||
# Joplin
|
||||
|
||||
- Update/Install:
|
||||
|
||||
```
|
||||
wget -O - https://raw.githubusercontent.com/laurent22/joplin/dev/Joplin_install_and_update.sh | bash
|
||||
```
|
||||
|
||||
You can then [synchronize it with NextCloud](https://joplinapp.org/help/apps/sync/nextcloud/).
|
||||
|
||||
# Update/backup OpenProject
|
||||
|
||||
[https://www.openproject.org/docs/installation-and-operations/installation/docker-compose/#upgrade](https://www.openproject.org/docs/installation-and-operations/installation/docker-compose/#upgrade)
|
||||
|
||||
Reference in New Issue
Block a user