- Added upstream objects
- Renamed host templates to nginx templates - Generate upstream templates - Better nginx error reporting when reloading - Use tparse for golang test reporting
This commit is contained in:
@@ -1,16 +1,16 @@
|
||||
import * as api from "./base";
|
||||
import { HostTemplatesResponse } from "./responseTypes";
|
||||
import { NginxTemplatesResponse } from "./responseTypes";
|
||||
|
||||
export async function getHostTemplates(
|
||||
export async function getNginxTemplates(
|
||||
offset = 0,
|
||||
limit = 10,
|
||||
sort?: string,
|
||||
filters?: { [key: string]: string },
|
||||
abortController?: AbortController,
|
||||
): Promise<HostTemplatesResponse> {
|
||||
): Promise<NginxTemplatesResponse> {
|
||||
const { result } = await api.get(
|
||||
{
|
||||
url: "host-templates",
|
||||
url: "nginx-templates",
|
||||
params: { limit, offset, sort, ...filters },
|
||||
},
|
||||
abortController,
|
@@ -9,7 +9,7 @@ export * from "./getDNSProviders";
|
||||
export * from "./getDNSProvidersAcmesh";
|
||||
export * from "./getHealth";
|
||||
export * from "./getHosts";
|
||||
export * from "./getHostTemplates";
|
||||
export * from "./getNginxTemplates";
|
||||
export * from "./getSettings";
|
||||
export * from "./getToken";
|
||||
export * from "./getUser";
|
||||
|
@@ -94,7 +94,7 @@ export interface Host {
|
||||
modifiedOn: number;
|
||||
userId: number;
|
||||
type: string;
|
||||
hostTemplateId: number;
|
||||
nginxTemplateId: number;
|
||||
listenInterface: number;
|
||||
domainNames: string[];
|
||||
upstreamId: number;
|
||||
@@ -108,16 +108,15 @@ export interface Host {
|
||||
hstsEnabled: boolean;
|
||||
hstsSubdomains: boolean;
|
||||
paths: string;
|
||||
upstreamOptions: string;
|
||||
advancedConfig: string;
|
||||
isDisabled: boolean;
|
||||
}
|
||||
|
||||
export interface HostTemplate {
|
||||
export interface NginxTemplate {
|
||||
id: number;
|
||||
createdOn: number;
|
||||
modifiedOn: number;
|
||||
userId: number;
|
||||
hostType: string;
|
||||
type: string;
|
||||
template: string;
|
||||
}
|
||||
|
@@ -3,7 +3,7 @@ import {
|
||||
CertificateAuthority,
|
||||
DNSProvider,
|
||||
Host,
|
||||
HostTemplate,
|
||||
NginxTemplate,
|
||||
Setting,
|
||||
Sort,
|
||||
User,
|
||||
@@ -53,6 +53,6 @@ export interface HostsResponse extends BaseResponse {
|
||||
items: Host[];
|
||||
}
|
||||
|
||||
export interface HostTemplatesResponse extends BaseResponse {
|
||||
items: HostTemplate[];
|
||||
export interface NginxTemplatesResponse extends BaseResponse {
|
||||
items: NginxTemplate[];
|
||||
}
|
||||
|
Reference in New Issue
Block a user