Repository navigation
Added
- Badges under the title of the README: CI status, latest release, licence (Apache-2.0) and Terraform 1.12+.
- README badge for the Go version (read from
go.mod), and the Go and Terraform logos on their badges. - A weekly
versionsworkflow (andscripts/check-versions.sh) that reports when a newer Floci, AWS provider or Terraform exists than the pinned ones. It only reports. SECURITY.mdsays that release binaries are unsigned and that the Homebrew cask removes the macOS quarantine flag.- 16 new mock exam questions (
questions/batch5.toml) for the thinnest objectives: 3f (destroy), 3g (formatting), 4a (resource and data blocks) and 4b (references). The bank has 183 questions. - Two hands-on exercises for objectives that were quiz only:
workflow7(terraform initand a module it cannot install, plan mode) andworkflow8(terraform validate, fix mode). 97 exercises. tflings sandbox: a scratch folder (<home>/sandbox/src) with a fake AWS account of its own, for trying Terraform outside the exercises.tflings sandboxprints the folder and the sealed environment,tflings sandbox <terraform arguments>runs Terraform there (its.tffiles get the same safety check as an exercise's),tflings sandbox --resetstarts over in a new account.aws upandwatchdo not empty Floci while the sandbox's state has resources. Not yet run against Floci: tested with provider-free configurations only.
Changed
- The release workflow runs
go test ./...(on Terraform 1.12, without Docker) before GoReleaser publishes, and theawsCI job runs its tests with-timeout 60m. - Two exercises folders on one machine no longer share state.
tflings initnow gives the folder a random salt (in.tflings.json), which names its scratch folders under tflings's home and goes into its fake AWS accounts, so aresetin one folder cannot delete the other's saved state. Folders made by an older version have no salt and keep working exactly as before. runnow records a pass in the progress file of the exercises folder it works on, the same file the reset counter lives in, instead of always in the current directory.- The safety check that refuses a configuration which could leave the fake AWS now also reads backend configuration files (
*.tfbackend,*.hcl) and refusesassume_rolewritten as an argument of the s3 backend.tflings tfrefuses-backend-configvalues that set credentials, a role or an endpoint other than Floci (or name a file that is not one of the exercise's own),-varvalues that give an endpoint another URL, and a-var-fileoutside the exercise's folder. tflings aws upandwatchnow say that they are about to empty Floci before they do it, not after.
Fixed
-
workflow6could not be done as its README says: everytflings tfcall cleared the exercise's scratch folder, so the saved plan oftflings tf workflow6 plan -out=tfplanwas gone beforeshowandapply tfplan. tflings now removes only the files it wrote itself; a saved plan or a file Terraform generated stays. The proof of a fix exercise's solution now runs each command the waytflings tfdoes, so a mistake like this is caught. -
Two tflings processes (a
watchin one terminal,tflings tforrunin another) could use the same exercise's scratch folder at once, and one could delete the folder under the other (the likely cause of a "chdir .../runs/.../src" error). The folder now has a lock that is held for the whole command,resetwaits for it (or says it could not and changes nothing), and a fix exercise is built in a side folder and moved into place when it is whole.
Changed
- Documentation brought up to date:
ROADMAP.md(phases that are done, the modes that need Terraform and Docker, the per-exercise plugin cache),CLAUDE.md(status, architecture, the automatic Floci reset exists) and the README (Go is needed only to build from source;updatealso refreshesinfo.tomlentries).
Install
go install github.com/cleonte/tflings/cmd/tflings@v0.10.0, brew install cleonte/tap/tflings (macOS), or download the archive for your system below and put tflings on your PATH. Then run tflings doctor, tflings init and tflings watch.
Exercises that use the AWS provider need Docker and a one-time tflings doctor --prefetch (about 250 MB); tflings aws up starts the local AWS emulator (Floci).