mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-22 18:29:19 +02:00
Handle token
This commit is contained in:
parent
2c8bf4f18c
commit
dc50190dc3
7 changed files with 232 additions and 83 deletions
|
@ -5,6 +5,7 @@ import logger from "@server/logger";
|
|||
import * as yaml from "js-yaml";
|
||||
import axios from "axios";
|
||||
import { db, exitNodes } from "@server/db";
|
||||
import { tokenManager } from "./tokenManager";
|
||||
|
||||
export class TraefikConfigManager {
|
||||
private intervalId: NodeJS.Timeout | null = null;
|
||||
|
@ -162,7 +163,8 @@ export class TraefikConfigManager {
|
|||
} | null> {
|
||||
try {
|
||||
const resp = await axios.get(
|
||||
`${config.getRawConfig().hybrid?.endpoint}/get-traefik-config`
|
||||
`${config.getRawConfig().hybrid?.endpoint}/traefik-config`,
|
||||
await tokenManager.getAuthHeader()
|
||||
);
|
||||
|
||||
if (resp.status !== 200) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue