hashicorp / hashicorp/nomad

Retrieving a git::http artifact fails on Modern distros

Open
#26,969 4 comments 0 reactions 1 assignee Claimed by @gulducat View on GitHub
stage/waiting-reply type/bug
Dominant language
Go
Stars
17k
Forks
2.1k
Avg merge
1d 9h
Merged PRs (30d)
105

Description

### Nomad version
nomad 1.9.5
nomad 1.8.4

### Operating system and Environment details
Centos 10 Stream

### Issue

Problems downloading artifacts from git repositories. The git client cannot access some directories when downloading artifacts.
This is evident on Linux operating systems with a 6 kernel on which the landlock kernel module is enabled. I was able to solve this problem by disabling it through the download menu.

### Reproduction steps

#### Expected Result

#### Actual Result

### Job file (if appropriate)

` artifact {
source = "git::https://nomad:***@***/infra/nomad-templates.git?ref=master"
destination = "$${NOMAD_TASK_DIR}/templates"
options {
depth = 1
}
}
`

### Nomad Server logs (if appropriate)

### Nomad Client logs (if appropriate)

Failed Artifact Download: failed to download artifact "git::https://nomad:@***/infra/nomad-templates.git": getter subprocess failed: exit status 1: failed to download artifact: error downloading 'https://nomad:redacted@***/infra/nomad-templates.git': /usr/bin/git exited with 128: Cloning into '/var/nomad/alloc/724e4df7-b08e-dc5e-8a21-6fa77b2299cf/nginx/local/templates'... warning: templates not found in /usr/share/git-core/templates error: unable to get random bytes for temporary file: Permission denied error: unable to get random bytes for temporary file: Permission denied fatal: Unable to create temporary file '/var/nomad/alloc/724e4df7-b08e-dc5e-8a21-6fa77b2299cf/nginx/local/templates/.git/objects/pack/tmp_pack_XXXXXX': Permission denied fatal: fetch-pack: invalid index-pack output

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.