Add endpoint for reading and updating site .env file (#564)

* feat(api): Add endpoint for reading site .env file

- Add GET /api/projects/{project}/servers/{server}/sites/{site}/env endpoint
- Add feature tests with SSH mocking

* added updating env

* fix coding style

* generate docs

---------

Co-authored-by: Saeed Vaziry <mr.saeedvaziry@gmail.com>
This commit is contained in:
Dimitar Yanakiev
2025-04-05 20:59:57 +03:00
committed by GitHub
parent 2a670146d8
commit e98e974e20
31 changed files with 2404 additions and 1395 deletions

View File

@ -63,7 +63,7 @@ endpoints:
responses:
-
status: 200
content: '{"data":[{"id":null,"site_id":null,"mode":301,"from":"eaque","to":"http:\/\/www.windler.info\/delectus-facilis-assumenda-consequatur-impedit-hic-dolorem-non-dolore.html","status":"ready","created_at":null,"updated_at":null},{"id":null,"site_id":null,"mode":308,"from":"neque","to":"http:\/\/raynor.biz\/velit-a-tempore-quas-explicabo-doloremque","status":"ready","created_at":null,"updated_at":null}],"links":{"first":"\/?page=1","last":"\/?page=1","prev":null,"next":null},"meta":{"current_page":1,"from":1,"last_page":1,"links":[{"url":null,"label":"&laquo; Previous","active":false},{"url":"\/?page=1","label":"1","active":true},{"url":null,"label":"Next &raquo;","active":false}],"path":"\/","per_page":25,"to":2,"total":2}}'
content: '{"data":[{"id":null,"site_id":null,"mode":307,"from":"ipsum","to":"http:\/\/fritsch.biz\/","status":"ready","created_at":null,"updated_at":null},{"id":null,"site_id":null,"mode":302,"from":"culpa","to":"http:\/\/www.huels.net\/aut-ut-ut-porro-non-rerum-voluptatum.html","status":"ready","created_at":null,"updated_at":null}],"links":{"first":"\/?page=1","last":"\/?page=1","prev":null,"next":null},"meta":{"current_page":1,"from":1,"last_page":1,"links":[{"url":null,"label":"&laquo; Previous","active":false},{"url":"\/?page=1","label":"1","active":true},{"url":null,"label":"Next &raquo;","active":false}],"path":"\/","per_page":25,"to":2,"total":2}}'
headers: []
description: ''
custom: []
@ -71,7 +71,7 @@ endpoints:
auth:
- headers
- Authorization
- 'Bearer 4fD5a38caEk1vZPdbVh66ge'
- 'Bearer cV16fevgEZhPadD43685akb'
controller: null
method: null
route: null
@ -135,7 +135,7 @@ endpoints:
name: from
description: ''
required: true
example: qui
example: odit
type: string
enumValues: []
exampleWasSpecified: false
@ -145,7 +145,7 @@ endpoints:
name: to
description: ''
required: true
example: voluptatum
example: incidunt
type: string
enumValues: []
exampleWasSpecified: false
@ -155,7 +155,7 @@ endpoints:
name: mode
description: ''
required: true
example: 302
example: 301
type: string
enumValues:
- 301
@ -166,9 +166,9 @@ endpoints:
nullable: false
custom: []
cleanBodyParameters:
from: qui
to: voluptatum
mode: 302
from: odit
to: incidunt
mode: 301
fileParameters: []
responses:
-
@ -181,7 +181,7 @@ endpoints:
auth:
- headers
- Authorization
- 'Bearer haPda6v1be64V8gcf3Dk5EZ'
- 'Bearer ZD45hPk638abev61EVcagdf'
controller: null
method: null
route: null
@ -265,7 +265,7 @@ endpoints:
auth:
- headers
- Authorization
- 'Bearer DVP8ve46k3dfhga5Z61bcEa'
- 'Bearer Ec3fDgdbae615aPh8k6vV4Z'
controller: null
method: null
route: null