mirror of
https://github.com/ershisan99/coolify.git
synced 2025-12-27 12:33:54 +00:00
feat: deploy specific commit for apps
feat: keep number of images locally to revert quickly
This commit is contained in:
@@ -53,7 +53,8 @@ export async function listAllSettings(request: FastifyRequest) {
|
||||
}
|
||||
export async function saveSettings(request: FastifyRequest<SaveSettings>, reply: FastifyReply) {
|
||||
try {
|
||||
const {
|
||||
let {
|
||||
numberOfDockerImagesKeptLocally,
|
||||
doNotTrack,
|
||||
fqdn,
|
||||
isAPIDebuggingEnabled,
|
||||
@@ -67,9 +68,12 @@ export async function saveSettings(request: FastifyRequest<SaveSettings>, reply:
|
||||
proxyDefaultRedirect
|
||||
} = request.body
|
||||
const { id } = await listSettings();
|
||||
if (numberOfDockerImagesKeptLocally) {
|
||||
numberOfDockerImagesKeptLocally = Number(numberOfDockerImagesKeptLocally)
|
||||
}
|
||||
await prisma.setting.update({
|
||||
where: { id },
|
||||
data: { doNotTrack, isRegistrationEnabled, dualCerts, isAutoUpdateEnabled, isDNSCheckEnabled, DNSServers, isAPIDebuggingEnabled, }
|
||||
data: { numberOfDockerImagesKeptLocally, doNotTrack, isRegistrationEnabled, dualCerts, isAutoUpdateEnabled, isDNSCheckEnabled, DNSServers, isAPIDebuggingEnabled, }
|
||||
});
|
||||
if (fqdn) {
|
||||
await prisma.setting.update({ where: { id }, data: { fqdn } });
|
||||
|
||||
@@ -2,6 +2,7 @@ import { OnlyId } from "../../../../types"
|
||||
|
||||
export interface SaveSettings {
|
||||
Body: {
|
||||
numberOfDockerImagesKeptLocally: number,
|
||||
doNotTrack: boolean,
|
||||
fqdn: string,
|
||||
isAPIDebuggingEnabled: boolean,
|
||||
|
||||
Reference in New Issue
Block a user