Skip to content

feat(ui): create a new job from a template with n, or from a file with :run - #103

Merged
ingvarch merged 2 commits into
mainfrom
feat/new-job
Oct 16, 2026
Merged

ingvarch merged 2 commits into
mainfrom
feat/new-job

Conversation

@ingvarch

Copy link
Copy Markdown
Owner

What changes

Start a new job from urga (#87), two commits.

  • n on the jobs list opens a job template in your editor: a service job web with one task, the docker driver and an nginx image, ready to change into yours. Saved, it goes through the plan, as an edit does, and y submits it. Saved unchanged, it sends nothing, as an edit does.
  • :run <file> reads a local job file, HCL or JSON, and opens its plan. ~/ is the home directory; a relative path is from where urga runs. A file that cannot be read says why, and :run with no path says it needs one.
  • A new job never replaces one of the same name. It is submitted with check-and-set at index 0, which Nomad refuses when the job exists, and when the plan already shows that it exists, the plan says A job named web exists already: a new one cannot replace it. and offers no submit.
  • The namespace is the one the file names; a file that names none goes to the namespace of the session, and to default when the session looks at all of them. The file is parsed without canonicalizing to tell the two apart.
  • After y, the watch of the deploy opens for a job that runs itself, as after any submit; a new periodic or parameterized job opens none.
  • Read-only mode offers no n, and :run says it is off. docs/keys.md and docs/jobs.md describe both.

Closes #87

Checklist

  • The test for this change was written first and failed
  • make check is green
  • The title is a conventional commit: feat(ui): ..., fix(nomad): ...

@ingvarch ingvarch added this to the v0.14.0 milestone Oct 16, 2026
@ingvarch ingvarch added documentation Improvements or additions to documentation enhancement New feature or request ui Screens, keys and the header nomad The client of the Nomad API and what it reads labels Oct 16, 2026
@ingvarch
ingvarch merged commit 83bfc3b into main Oct 16, 2026
5 checks passed
@ingvarch
ingvarch deleted the feat/new-job branch October 16, 2026 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request nomad The client of the Nomad API and what it reads ui Screens, keys and the header

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create a new job from a template or from a file

1 participant