add searxng

This commit is contained in:
Andras Bacsai
2022-10-20 09:18:13 +02:00
parent 21f3a70788
commit 22cbbec960
4 changed files with 157 additions and 19 deletions

View File

@@ -698,9 +698,15 @@ export async function startService(request: FastifyRequest<ServiceStartStop>) {
const { workdir } = await createDirectories({ repository: type, buildId: id });
const template: any = await parseAndFindServiceTemplates(service, workdir, true)
const network = destinationDockerId && destinationDocker.network;
const config = {};
for (const service in template.services) {
let newEnviroments = []
for (const environment of template.services[service].environment) {
const [env, value] = environment.split("=");
if (!value.startsWith('$$secret') && value !== '') {
newEnviroments.push(`${env}=${value}`)
}
}
config[service] = {
container_name: service,
build: template.services[service].build || undefined,
@@ -709,9 +715,11 @@ export async function startService(request: FastifyRequest<ServiceStartStop>) {
expose: template.services[service].ports,
// ...(exposePort ? { ports: [`${exposePort}:${port}`] } : {}),
volumes: template.services[service].volumes,
environment: template.services[service].environment,
environment: newEnviroments,
depends_on: template.services[service].depends_on,
ulimits: template.services[service].ulimits,
cap_drop: template.services[service].cap_drop,
cap_add: template.services[service].cap_add,
labels: makeLabelForServices(type),
...defaultComposeConfiguration(network),
}