From 72b97085135858be454e30a78a929dae81a98a78 Mon Sep 17 00:00:00 2001 From: Jo Van Bulck Date: Sat, 5 Oct 2024 21:53:44 +0200 Subject: [PATCH 1/2] dev: enable adminer db viewer service Signed-off-by: Jo Van Bulck --- .devcontainer/README.md | 4 ++-- .devcontainer/devcontainer.json | 2 +- .devcontainer/docker-compose.yml | 8 ++++++++ 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.devcontainer/README.md b/.devcontainer/README.md index 82c31dc24..064f2c2d3 100644 --- a/.devcontainer/README.md +++ b/.devcontainer/README.md @@ -9,7 +9,7 @@ After the container starts up, follow these steps: - Username: `admin` - Password: `admin` -Note: MariaDB is set up automatically (db=`nextcloud`, user=`nextcloud`, password=`nextcloud`) +Note: MariaDB is set up automatically (db=`nextcloud`, user=`nextcloud`, password=`nextcloud`); Adminer for graphical database management is available on port 8080. To run OCC commands in the container, use the following command: @@ -21,4 +21,4 @@ To watch changes in UI build: ```bash make watch-js -``` \ No newline at end of file +``` diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 7a6396c63..7be2b5e5c 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -9,7 +9,7 @@ "features": {}, // Use 'forwardPorts' to make a list of ports inside the container available locally. - "forwardPorts": [80], + "forwardPorts": [80,8080], "postCreateCommand": "bash .devcontainer/postCreate.sh", // "postStartCommand": "make watch-js", // Configure tool-specific properties. diff --git a/.devcontainer/docker-compose.yml b/.devcontainer/docker-compose.yml index 5aa69c943..e8e1a5207 100644 --- a/.devcontainer/docker-compose.yml +++ b/.devcontainer/docker-compose.yml @@ -26,6 +26,9 @@ services: - PHP_MEMORY_LIMIT=1G - PHP_UPLOAD_LIMIT=1G - DEBIAN_FRONTEND=noninteractive + ports: + - 80:80 + - 8080:8080 db: image: mariadb:11 @@ -42,6 +45,11 @@ services: - MARIADB_AUTO_UPGRADE=1 - MARIADB_INITDB_SKIP_TZINFO=1 + adminer: + image: adminer + restart: always + network_mode: service:nextcloud + redis: image: redis:alpine pull_policy: always From 0eb1e7b65db84abc6d1c067b62c96cdd0abf8cdc Mon Sep 17 00:00:00 2001 From: Jo Van Bulck Date: Fri, 11 Oct 2024 08:30:05 -0700 Subject: [PATCH 2/2] dev: clarify app asset cache See also: - - --- .devcontainer/README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.devcontainer/README.md b/.devcontainer/README.md index 064f2c2d3..88d8c71d7 100644 --- a/.devcontainer/README.md +++ b/.devcontainer/README.md @@ -22,3 +22,9 @@ To watch changes in UI build: ```bash make watch-js ``` + +Note: Nextcloud automatically caches app assets (including javascript) based on the version number, so you'll have to force-reload your browser window. Alternatively, to ensure caches are invalidated, you can: + +1. Change the version number in `appinfo/info.xml` +2. Build the app using `make watch-js` (or `make build-js`/`make build-js-production` for a static build) +3. Inform nextcloud of the upgrade via `sudo -E -u www-data php /var/www/html/occ upgrade` \ No newline at end of file