Skip to content

Commit 4e12b40

Browse files
committed
Merge branch 'main' into tests-php84
* main: (103 commits) Update PHPStan parameters Change schedule running Fix dutch translations (#231) fix: remove additional prompt for name (#227) [fix] name mapping in request data classes (#226) fix: define getTitle method on Settings pages to use localised name (#224) Set OG images Fix code styling Demo Mode (#223) Fix code styling fix: make user command does not accept a name argument (#216) Apply ordering of component groups to status page Use root language for local dialects Compile Assets Updated PH localization (#213) Bump vite from 5.4.8 to 5.4.14 (#214) Fix code styling Support the `HTTP_REMOTE_USER` header (#208) New adjustments added for German translation and added Dutch (#209) Fix code styling ...
2 parents 8cd20c6 + 0319a17 commit 4e12b40

File tree

384 files changed

+9834
-1404
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

384 files changed

+9834
-1404
lines changed

.github/workflows/build-api-docs.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Build API Reference
2+
3+
on:
4+
schedule:
5+
- cron: '0 7 * * *'
6+
workflow_dispatch:
7+
8+
env:
9+
DOCS_REPOSITORY: cachethq/docs
10+
DOCS_BRANCH: 3.x
11+
12+
jobs:
13+
build:
14+
name: Build
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v4
19+
20+
- name: Setup PHP
21+
uses: shivammathur/setup-php@v2
22+
with:
23+
php-version: 8.3
24+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
25+
26+
- name: Install dependencies
27+
run: composer install
28+
29+
- name: Install Scramble PRO
30+
run: |
31+
composer config repositories.scramble-pro '{"type": "composer", "url": "https://satis.dedoc.co"}'
32+
composer config http-basic.satis.dedoc.co ${{ secrets.SCRAMBLE_USERNAME }} ${{ secrets.SCRAMBLE_KEY }}
33+
composer require dedoc/scramble-pro:0.7.0-alpha.1 --dev
34+
35+
- name: Checkout documentation repository
36+
uses: actions/checkout@v4
37+
with:
38+
token: ${{ secrets.DOCS_API_TOKEN }}
39+
repository: ${{ env.DOCS_REPOSITORY }}
40+
ref: ${{ env.DOCS_BRANCH }}
41+
path: 'docs-repository'
42+
43+
- name: Build API docs
44+
run: php vendor/bin/testbench scramble:export --path=docs-repository/api-reference/openapi.json
45+
46+
- name: Commit and push generated specification
47+
uses: stefanzweifel/git-auto-commit-action@v5
48+
with:
49+
commit_message: "Generated API specification from ${{ github.repository }}/${{ github.ref}}@${{ github.sha }}"
50+
repository: "docs-repository"

.github/workflows/run-tests.yml

Lines changed: 118 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ jobs:
9898
DB_USERNAME: cachet
9999
DB_PASSWORD: password
100100

101-
postgres:
101+
postgres13:
102102
runs-on: ubuntu-latest
103103

104104
services:
@@ -155,6 +155,120 @@ jobs:
155155
DB_USERNAME: cachet
156156
DB_PASSWORD: password
157157

158+
postgres14:
159+
runs-on: ubuntu-latest
160+
161+
services:
162+
postgres:
163+
image: postgres:14
164+
env:
165+
POSTGRES_DB: cachet
166+
POSTGRES_USER: cachet
167+
POSTGRES_PASSWORD: password
168+
ports:
169+
- 5432:5432
170+
options: --health-cmd="pg_isready" --health-interval=10s --health-timeout=5s --health-retries=3
171+
172+
strategy:
173+
fail-fast: false
174+
matrix:
175+
php: [ 8.3, 8.2 ]
176+
laravel: [ 11.x ]
177+
stability: [ prefer-lowest, prefer-stable ]
178+
179+
name: Tests - P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - PostgreSQL 14
180+
181+
steps:
182+
- name: Checkout code
183+
uses: actions/checkout@v4
184+
185+
- name: Setup PHP
186+
uses: shivammathur/setup-php@v2
187+
with:
188+
php-version: ${{ matrix.php }}
189+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
190+
coverage: none
191+
192+
- name: Install dependencies
193+
run: |
194+
composer require "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-update
195+
composer update --${{ matrix.stability }} --prefer-dist --no-interaction
196+
197+
- name: Install frontend dependencies
198+
run: npm ci
199+
200+
- name: Build assets
201+
run: npm run build
202+
203+
- name: Build tests environment
204+
run: composer build
205+
206+
- name: Execute tests
207+
run: composer test
208+
env:
209+
DB_CONNECTION: mysql
210+
DB_HOST: localhost
211+
DB_DATABASE: cachet
212+
DB_USERNAME: cachet
213+
DB_PASSWORD: password
214+
215+
postgres15:
216+
runs-on: ubuntu-latest
217+
218+
services:
219+
postgres:
220+
image: postgres:15
221+
env:
222+
POSTGRES_DB: cachet
223+
POSTGRES_USER: cachet
224+
POSTGRES_PASSWORD: password
225+
ports:
226+
- 5432:5432
227+
options: --health-cmd="pg_isready" --health-interval=10s --health-timeout=5s --health-retries=3
228+
229+
strategy:
230+
fail-fast: false
231+
matrix:
232+
php: [ 8.3, 8.2 ]
233+
laravel: [ 11.x ]
234+
stability: [ prefer-lowest, prefer-stable ]
235+
236+
name: Tests - P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - PostgreSQL 15
237+
238+
steps:
239+
- name: Checkout code
240+
uses: actions/checkout@v4
241+
242+
- name: Setup PHP
243+
uses: shivammathur/setup-php@v2
244+
with:
245+
php-version: ${{ matrix.php }}
246+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
247+
coverage: none
248+
249+
- name: Install dependencies
250+
run: |
251+
composer require "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-update
252+
composer update --${{ matrix.stability }} --prefer-dist --no-interaction
253+
254+
- name: Install frontend dependencies
255+
run: npm ci
256+
257+
- name: Build assets
258+
run: npm run build
259+
260+
- name: Build tests environment
261+
run: composer build
262+
263+
- name: Execute tests
264+
run: composer test
265+
env:
266+
DB_CONNECTION: mysql
267+
DB_HOST: localhost
268+
DB_DATABASE: cachet
269+
DB_USERNAME: cachet
270+
DB_PASSWORD: password
271+
158272
sqlite:
159273
runs-on: ubuntu-latest
160274
strategy:
@@ -199,7 +313,9 @@ jobs:
199313
needs:
200314
- static-analysis
201315
- mysql
202-
- postgres
316+
- postgres13
317+
- postgres14
318+
- postgres15
203319
- sqlite
204320
runs-on: ubuntu-latest
205321

README.md

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,13 @@ Cachet 3.x is currently in development and is not yet completely ready for produ
3939
- [ ] Subscribers
4040
- [x] API
4141
- Complete but may need some tweaks as we progress.
42-
- [ ] Webhooks
42+
- [x] Webhooks
4343
- [x] Dashboard
4444
- [x] Localization
45-
- [ ] Status Page Customization
45+
- [x] Status Page Customization
46+
- [ ] Meta
47+
- [ ] Tags
48+
- [x] User Management
4649

4750
## Stack
4851

@@ -55,17 +58,7 @@ Cachet is built on:
5558

5659
## Development
5760

58-
1. Clone this repository.
59-
2. Run the following commands from within the `core` directory:
60-
```shell
61-
npm install
62-
composer update
63-
composer dev
64-
```
65-
3. Develop Cachet.
66-
67-
> [!NOTE]
68-
> HMR is not enabled. Manual refreshes are needed to view changes.
61+
To get started developing Cachet, please check out the [Development Guide](https://docs.cachethq.io/v3.x/development).
6962

7063
### Dashboard Credentials
7164

@@ -81,6 +74,7 @@ Login to the account at `/dashboard` and use credentials:
8174
<a href="https://jump24.co.uk"><img width="100px" src="https://github.com/jumptwentyfour.png" alt="Jump24"></a>
8275
<a href="https://dreamtilt.com.au"><img width="100px" src="https://github.com/dreamtilt.png" alt="Dreamtilt"></a>
8376
<a href="https://xyphen-it.nl"><img width="100px" src="https://github.com/xyphen-it.png" alt="Xyphen-IT"></a>
77+
<a href="https://coderabbit.ai/"><img width="100px" src="https://github.com/coderabbitai.png" alt="Code Rabbit"></a>
8478
</p>
8579

8680
## Security Vulnerabilities

composer.json

Lines changed: 35 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
{
22
"name": "cachethq/core",
33
"description": "Cachet core package.",
4+
"license": "proprietary",
45
"keywords": [
56
"cachet",
67
"status page",
78
"laravel"
89
],
9-
"homepage": "https://cachethq.io",
10-
"license": "proprietary",
11-
"support": {
12-
"issues": "https://github.com/cachethq/core/issues",
13-
"source": "https://github.com/cachethq/core"
14-
},
1510
"authors": [
1611
{
1712
"name": "James Brooks",
1813
"email": "james@alt-three.com"
1914
}
2015
],
16+
"homepage": "https://cachethq.io",
17+
"support": {
18+
"issues": "https://github.com/cachethq/core/issues",
19+
"source": "https://github.com/cachethq/core"
20+
},
2121
"require": {
2222
"php": "^8.2",
2323
"doctrine/dbal": "^3.6",
@@ -29,21 +29,26 @@
2929
"illuminate/events": "^11.23.0",
3030
"illuminate/queue": "^11.23.0",
3131
"illuminate/support": "^11.23.0",
32+
"laravel/sanctum": "^4.0",
3233
"nesbot/carbon": "^2.70",
3334
"spatie/laravel-data": "^4.11",
3435
"spatie/laravel-query-builder": "^5.5",
3536
"spatie/laravel-settings": "^3.2",
36-
"timacdonald/json-api": "^v1.0.0-beta.4",
37+
"spatie/laravel-webhook-server": "^3.8",
38+
"timacdonald/json-api": "^1.0.0-beta.4",
3739
"twig/twig": "^3.0"
3840
},
3941
"require-dev": {
42+
"dedoc/scramble": "0.12.0-alpha.1",
4043
"larastan/larastan": "^3.0",
4144
"laravel/pail": "^1.1",
4245
"orchestra/testbench": "^9.5.1",
4346
"pestphp/pest": "^3.2",
4447
"pestphp/pest-plugin-laravel": "^3.0",
4548
"pestphp/pest-plugin-livewire": "*"
4649
},
50+
"minimum-stability": "dev",
51+
"prefer-stable": true,
4752
"autoload": {
4853
"psr-4": {
4954
"Cachet\\": "src",
@@ -53,38 +58,18 @@
5358
},
5459
"autoload-dev": {
5560
"psr-4": {
56-
"Cachet\\Tests\\": "tests",
5761
"Cachet\\Database\\Factories\\": "database/factories",
62+
"Cachet\\Tests\\": "tests",
5863
"Workbench\\App\\": "workbench/app/",
5964
"Workbench\\Database\\Factories\\": "workbench/database/factories/",
6065
"Workbench\\Database\\Seeders\\": "workbench/database/seeders/"
6166
}
6267
},
63-
"scripts": {
64-
"post-autoload-dump": "@prepare",
65-
"test": "vendor/bin/pest",
66-
"canvas": "@php vendor/bin/canvas",
67-
"clear": "@php vendor/bin/testbench package:purge-skeleton --ansi",
68-
"prepare": "@php vendor/bin/testbench package:discover --ansi",
69-
"build": [
70-
"@prepare",
71-
"@clear",
72-
"@php vendor/bin/testbench workbench:build"
73-
],
74-
"dev": [
75-
"@build",
76-
"Composer\\Config::disableProcessTimeout",
77-
"npx concurrently -c \"#93c5fd,#c4b5fd,#fb7185,#fdba74\" \"php vendor/bin/testbench serve\" \"php vendor/bin/testbench queue:listen --tries=1\" \"php vendor/bin/testbench pail\" \"npm run dev\" --names=server,queue,logs,vite"
78-
],
79-
"start": [
80-
"@dev"
81-
]
82-
},
8368
"config": {
84-
"sort-packages": true,
8569
"allow-plugins": {
8670
"pestphp/pest-plugin": true
87-
}
71+
},
72+
"sort-packages": true
8873
},
8974
"extra": {
9075
"branch-alias": {
@@ -97,6 +82,24 @@
9782
]
9883
}
9984
},
100-
"minimum-stability": "dev",
101-
"prefer-stable": true
85+
"scripts": {
86+
"post-autoload-dump": "@prepare",
87+
"build": [
88+
"@prepare",
89+
"@clear",
90+
"@php vendor/bin/testbench workbench:build"
91+
],
92+
"canvas": "@php vendor/bin/canvas",
93+
"clear": "@php vendor/bin/testbench package:purge-skeleton --ansi",
94+
"dev": [
95+
"@build",
96+
"Composer\\Config::disableProcessTimeout",
97+
"npx concurrently -c \"#93c5fd,#c4b5fd,#fb7185,#fdba74\" \"php vendor/bin/testbench serve\" \"php vendor/bin/testbench queue:listen --tries=1\" \"php vendor/bin/testbench pail\" \"npm run dev\" --names=server,queue,logs,vite"
98+
],
99+
"prepare": "@php vendor/bin/testbench package:discover --ansi",
100+
"start": [
101+
"@dev"
102+
],
103+
"test": "vendor/bin/pest"
104+
}
102105
}

0 commit comments

Comments
 (0)