mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-08 01:12:34 +00:00
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:
@ -41,7 +41,7 @@ endpoints:
|
||||
responses:
|
||||
-
|
||||
status: 200
|
||||
content: '{"data":[{"id":5,"project_id":null,"global":true,"name":"Dawson Ratke IV","provider":"github","created_at":"2025-04-05T17:35:56.000000Z","updated_at":"2025-04-05T17:35:56.000000Z"},{"id":6,"project_id":null,"global":true,"name":"Miss Caterina Mann DVM","provider":"github","created_at":"2025-04-05T17:35:56.000000Z","updated_at":"2025-04-05T17:35:56.000000Z"}],"links":{"first":"\/?page=1","last":"\/?page=1","prev":null,"next":null},"meta":{"current_page":1,"from":1,"last_page":1,"links":[{"url":null,"label":"« Previous","active":false},{"url":"\/?page=1","label":"1","active":true},{"url":null,"label":"Next »","active":false}],"path":"\/","per_page":25,"to":2,"total":2}}'
|
||||
content: '{"data":[{"id":5,"project_id":null,"global":true,"name":"Zella Robel","provider":"github","created_at":"2025-04-05T17:48:03.000000Z","updated_at":"2025-04-05T17:48:03.000000Z"},{"id":6,"project_id":null,"global":true,"name":"Jairo Williamson","provider":"github","created_at":"2025-04-05T17:48:03.000000Z","updated_at":"2025-04-05T17:48:03.000000Z"}],"links":{"first":"\/?page=1","last":"\/?page=1","prev":null,"next":null},"meta":{"current_page":1,"from":1,"last_page":1,"links":[{"url":null,"label":"« Previous","active":false},{"url":"\/?page=1","label":"1","active":true},{"url":null,"label":"Next »","active":false}],"path":"\/","per_page":25,"to":2,"total":2}}'
|
||||
headers: []
|
||||
description: ''
|
||||
custom: []
|
||||
@ -49,7 +49,7 @@ endpoints:
|
||||
auth:
|
||||
- headers
|
||||
- Authorization
|
||||
- 'Bearer vVc6ebd865ZkEgf431haDaP'
|
||||
- 'Bearer e3f4ag8hkb5vZcDadPEV661'
|
||||
controller: null
|
||||
method: null
|
||||
route: null
|
||||
@ -91,7 +91,7 @@ endpoints:
|
||||
name: provider
|
||||
description: 'The provider'
|
||||
required: true
|
||||
example: github
|
||||
example: gitlab
|
||||
type: string
|
||||
enumValues:
|
||||
- gitlab
|
||||
@ -104,7 +104,7 @@ endpoints:
|
||||
name: name
|
||||
description: 'The name of the storage provider.'
|
||||
required: true
|
||||
example: est
|
||||
example: molestias
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -114,7 +114,7 @@ endpoints:
|
||||
name: token
|
||||
description: 'The token if provider requires api token'
|
||||
required: true
|
||||
example: ea
|
||||
example: in
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -124,7 +124,7 @@ endpoints:
|
||||
name: url
|
||||
description: 'The URL if the provider is Gitlab and it is self-hosted'
|
||||
required: true
|
||||
example: 'http://koepp.info/maiores-nostrum-consequuntur-dicta-iure-ullam'
|
||||
example: 'https://www.white.com/aperiam-dolor-nemo-qui-rerum-quod-quas'
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -134,7 +134,7 @@ endpoints:
|
||||
name: username
|
||||
description: 'The username if the provider is Bitbucket'
|
||||
required: true
|
||||
example: ducimus
|
||||
example: consectetur
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -144,24 +144,24 @@ endpoints:
|
||||
name: password
|
||||
description: 'The password if the provider is Bitbucket'
|
||||
required: true
|
||||
example: 'S#AHlt"?l6SDU^b?T6'
|
||||
example: 'y*P4_]ZdjE_:'
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
nullable: false
|
||||
custom: []
|
||||
cleanBodyParameters:
|
||||
provider: github
|
||||
name: est
|
||||
token: ea
|
||||
url: 'http://koepp.info/maiores-nostrum-consequuntur-dicta-iure-ullam'
|
||||
username: ducimus
|
||||
password: 'S#AHlt"?l6SDU^b?T6'
|
||||
provider: gitlab
|
||||
name: molestias
|
||||
token: in
|
||||
url: 'https://www.white.com/aperiam-dolor-nemo-qui-rerum-quod-quas'
|
||||
username: consectetur
|
||||
password: 'y*P4_]ZdjE_:'
|
||||
fileParameters: []
|
||||
responses:
|
||||
-
|
||||
status: 200
|
||||
content: '{"id":5,"project_id":null,"global":true,"name":"Dr. Adella Greenholt","provider":"github","created_at":"2025-04-05T17:35:56.000000Z","updated_at":"2025-04-05T17:35:56.000000Z"}'
|
||||
content: '{"id":5,"project_id":null,"global":true,"name":"Miss Claudine Goyette","provider":"github","created_at":"2025-04-05T17:48:03.000000Z","updated_at":"2025-04-05T17:48:03.000000Z"}'
|
||||
headers: []
|
||||
description: ''
|
||||
custom: []
|
||||
@ -169,7 +169,7 @@ endpoints:
|
||||
auth:
|
||||
- headers
|
||||
- Authorization
|
||||
- 'Bearer geVfZhE85aa4c16Pbk63Dvd'
|
||||
- 'Bearer DfegP56vkEa364Zbhda8V1c'
|
||||
controller: null
|
||||
method: null
|
||||
route: null
|
||||
@ -223,7 +223,7 @@ endpoints:
|
||||
responses:
|
||||
-
|
||||
status: 200
|
||||
content: '{"id":5,"project_id":null,"global":true,"name":"Hettie Farrell","provider":"github","created_at":"2025-04-05T17:35:56.000000Z","updated_at":"2025-04-05T17:35:56.000000Z"}'
|
||||
content: '{"id":5,"project_id":null,"global":true,"name":"Mona Stark","provider":"github","created_at":"2025-04-05T17:48:03.000000Z","updated_at":"2025-04-05T17:48:03.000000Z"}'
|
||||
headers: []
|
||||
description: ''
|
||||
custom: []
|
||||
@ -231,7 +231,7 @@ endpoints:
|
||||
auth:
|
||||
- headers
|
||||
- Authorization
|
||||
- 'Bearer P1kgc5vVaD4ZhE8aed6b36f'
|
||||
- 'Bearer ePc6fb65vh1Z4aakE3Dgd8V'
|
||||
controller: null
|
||||
method: null
|
||||
route: null
|
||||
@ -284,7 +284,7 @@ endpoints:
|
||||
name: name
|
||||
description: 'The name of the storage provider.'
|
||||
required: true
|
||||
example: sunt
|
||||
example: non
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -294,7 +294,7 @@ endpoints:
|
||||
name: token
|
||||
description: 'The token if provider requires api token'
|
||||
required: true
|
||||
example: est
|
||||
example: sunt
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -304,7 +304,7 @@ endpoints:
|
||||
name: url
|
||||
description: 'The URL if the provider is Gitlab and it is self-hosted'
|
||||
required: true
|
||||
example: 'http://www.fay.com/quisquam-autem-illum-omnis-quo-enim-eligendi-velit'
|
||||
example: 'https://www.frami.org/ex-at-minus-rerum-quo-minus-ea'
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -314,7 +314,7 @@ endpoints:
|
||||
name: username
|
||||
description: 'The username if the provider is Bitbucket'
|
||||
required: true
|
||||
example: ab
|
||||
example: natus
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -324,7 +324,7 @@ endpoints:
|
||||
name: password
|
||||
description: 'The password if the provider is Bitbucket'
|
||||
required: true
|
||||
example: 'M@-*%?(B(UNE~Ibc#'
|
||||
example: 'A^">*m{p]DI'
|
||||
type: string
|
||||
enumValues: []
|
||||
exampleWasSpecified: false
|
||||
@ -334,7 +334,7 @@ endpoints:
|
||||
name: global
|
||||
description: 'Accessible in all projects'
|
||||
required: true
|
||||
example: false
|
||||
example: true
|
||||
type: string
|
||||
enumValues:
|
||||
- true
|
||||
@ -343,17 +343,17 @@ endpoints:
|
||||
nullable: false
|
||||
custom: []
|
||||
cleanBodyParameters:
|
||||
name: sunt
|
||||
token: est
|
||||
url: 'http://www.fay.com/quisquam-autem-illum-omnis-quo-enim-eligendi-velit'
|
||||
username: ab
|
||||
password: 'M@-*%?(B(UNE~Ibc#'
|
||||
global: false
|
||||
name: non
|
||||
token: sunt
|
||||
url: 'https://www.frami.org/ex-at-minus-rerum-quo-minus-ea'
|
||||
username: natus
|
||||
password: 'A^">*m{p]DI'
|
||||
global: true
|
||||
fileParameters: []
|
||||
responses:
|
||||
-
|
||||
status: 200
|
||||
content: '{"id":5,"project_id":null,"global":true,"name":"Jadyn Hyatt","provider":"github","created_at":"2025-04-05T17:35:56.000000Z","updated_at":"2025-04-05T17:35:56.000000Z"}'
|
||||
content: '{"id":5,"project_id":null,"global":true,"name":"Neha Little","provider":"github","created_at":"2025-04-05T17:48:03.000000Z","updated_at":"2025-04-05T17:48:03.000000Z"}'
|
||||
headers: []
|
||||
description: ''
|
||||
custom: []
|
||||
@ -361,7 +361,7 @@ endpoints:
|
||||
auth:
|
||||
- headers
|
||||
- Authorization
|
||||
- 'Bearer 63kaaDdg5fvVPeEh18b4c6Z'
|
||||
- 'Bearer v3f6aaPk61Ze8hVdDbE5g4c'
|
||||
controller: null
|
||||
method: null
|
||||
route: null
|
||||
@ -423,7 +423,7 @@ endpoints:
|
||||
auth:
|
||||
- headers
|
||||
- Authorization
|
||||
- 'Bearer vb6ZE63ea8Da5fPhdkcVg14'
|
||||
- 'Bearer fgk61vD68E4cZhP3bV5adea'
|
||||
controller: null
|
||||
method: null
|
||||
route: null
|
||||
|
Reference in New Issue
Block a user