Skip to content

{kola,kolaTestIso}: workaround issue with accessDenied from dir()#124

Merged
dustymabe merged 1 commit into
coreos:mainfrom
dustymabe:dusty-add-cd
Oct 17, 2022
Merged

{kola,kolaTestIso}: workaround issue with accessDenied from dir()#124
dustymabe merged 1 commit into
coreos:mainfrom
dustymabe:dusty-add-cd

Conversation

@dustymabe

@dustymabe dustymabe commented Oct 17, 2022

Copy link
Copy Markdown
Member

When using dir() in the kola and kolaTestIso jobs the cd is happening on the controller (not in the COSA pod) so if the directory isn't under the env.WORKSPACE directory then we get a permission denied error.

Let's go back to using a cd ${cosaDir} for now to workaround this while we find better solutions. This cd ${cosaDir} will have no effect on multi-arch where we'll be operating in a remote session anyway.

@jlebon jlebon left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! As discussed OOB, we will circle back on this and rework things to make it cleaner.

When using dir() in the kola and kolaTestIso jobs the cd is happening on the controller (not in the COSA pod).

To clarify, that was my first theory but in testing, the fact that it does work if it's a subdir of the workspace seems to indicate it's more subtle than that.

When using `dir()` in the kola and kolaTestIso jobs we are getting a
permission denied error if the directory is isn't under the env.WORKSPACE
directory.

Let's go back to using a `cd ${cosaDir}` for now to workaround this while
we find better solutions. This `cd ${cosaDir}` will have no effect on
multi-arch where we'll be operating in a remote session anyway.
@dustymabe

Copy link
Copy Markdown
Member Author

To clarify, that was my first theory but in testing, the fact that it does work if it's a subdir of the workspace seems to indicate it's more subtle than that.

updated the commit message to drop that possibly inaccurate detail.

@dustymabe dustymabe merged commit b2bbc1b into coreos:main Oct 17, 2022
jlebon added a commit to jlebon/coreos-ci-lib that referenced this pull request Oct 17, 2022
Support for the cosa directory being different from the working
directory makes implementation details messier.

Drop support for it.

Callers can still have their cosa directories be different from the
Jenkins workspace by first wrapping calls to the cosa APIs here in a
call to `dir(cosaDir)`:

```
dir(cosaDir) {
        cosaBuild(skipKola: true)
        kola()
        kolaTestIso(skipMetal4k: true)
}
```

The cosa directory currently needs to be a subdirectory of the workspace
(see coreos#124).
@jlebon

jlebon commented Oct 17, 2022

Copy link
Copy Markdown
Member

LGTM! As discussed OOB, we will circle back on this and rework things to make it cleaner.

Draft in #125.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants