---
title: "Concourse: task file vars resolved before parsing, Go"
description: "A fix in Concourse, the CI/CD system written in Go: task file vars are resolved before parsing, so they also work in numeric fields such as container_limits."
url: "https://vulcode.com/en/opensource/contributions/concourse"
lang: "en"
---

[All contributions](https://vulcode.com/en/opensource/contributions)

concourse/concourse

# Concourse

A container-based automation system written in Go and used mostly for CI/CD. Pipelines and tasks are described in YAML files.

[See the repository](https://github.com/concourse/concourse) [All contributions](https://vulcode.com/en/opensource/contributions)

- **Language**: Go
- **GitHub stars**: 7,944
- **Merged changes**: 1
- **Project site**: [concourse-ci.org](https://concourse-ci.org)

## What we changed

Variables in a task file are interpolated before the file is parsed, so they also work in numeric fields such as the container memory and CPU limits.

### What this work shows

- Variable interpolation in YAML config

- Concourse CI/CD pipelines

- Go interfaces and layered config sources

- Tests with Ginkgo and Gomega

What was broken

### A var in a numeric field broke the task

The task file was parsed before its vars were resolved. With memory: ((container_mem_limit)) under container_limits the parser saw text where it expected a number and stopped the build with cpu/memory limit must be an integer.

How we fixed it

### Resolve first, parse after

The file is read as raw text, its vars are resolved there, and the result is parsed once. This pass now runs for every task file, not only when vars is set, and the error message names the file.

[#9717](https://github.com/concourse/concourse/pull/9717)

## Merged change 1

- [#9717 Interpolate task file vars before parsing the file Merged 5 October 2026](https://github.com/concourse/concourse/pull/9717)

## What it taught us

The order in which configuration is processed decides which fields variables work in, and it can be changed without affecting existing pipelines. The tests also cover a file that is still invalid once its vars are resolved.

[More about this technology: Golang](https://vulcode.com/en/technologies/go)

## Other projects we write code for

- [**urfave/cli** Go · 24,329 stars A declarative Go package for building command line tools.](https://vulcode.com/en/opensource/contributions/urfave-cli)

- [**chezmoi** Go · 22,342 stars A dotfiles manager that keeps the same settings on many different machines, securely.](https://vulcode.com/en/opensource/contributions/chezmoi)

- [**goquery** Go · 14,995 stars A Go library for traversing and changing HTML documents in the style of jQuery, built on the golang.org/x/net/html parser.](https://vulcode.com/en/opensource/contributions/goquery)

- [**Ebitengine** Go · 13,647 stars A 2D game engine in Go, used in games released for computers, phones, browsers and consoles.](https://vulcode.com/en/opensource/contributions/ebiten)

- [**Fission** Go · 8,950 stars A serverless functions framework for Kubernetes that runs code as functions and scales them down to zero when they are idle.](https://vulcode.com/en/opensource/contributions/fission)

- [**dromara/carbon** Go · 5,225 stars A Go package for dates and times with a simple, readable API, with helpers such as the start and end of a minute, a day or a century.](https://vulcode.com/en/opensource/contributions/dromara-carbon)

## Describe your project.

A free quote comes back within an hour during working hours.

### Rather skip the form?

Ask in the chat or write to us directly.

Open the chat

- **Email**: [hello@vulcode.com](mailto:hello@vulcode.com)
- **Phone**: [+48 576 043 920](tel:+48576043920)
- **Discord**: [discord.gg/vulcode](https://discord.gg/vulcode)
