martinthomson / i-d-template

A template for IETF internet draft git repositories
Other
207 stars 182 forks source link

Adding extra Ruby gems breaks the `ghpages` target #346

Closed thomas-fossati closed 1 year ago

thomas-fossati commented 1 year ago

We are adding three extra gems as part of our build, and the "Update Editor's Copy" workflow fails like this:

> Update GitHub Pages
[...]
touch: cannot touch '/tmp/.gems/.i-d-template.opt': No such file or directory
make[1]: *** [lib/deps.mk:99: /tmp/.gems/.i-d-template.opt] Error 1
mkdir -p /tmp/ghpages86/draft-ietf-rats-corim-00
make[1]: Target 'ghpages' not remade because of errors.
make: *** [lib/ghpages.mk:121: ghpages] Error 2

For the complete trace, see https://github.com/ietf-rats-wg/draft-ietf-rats-corim/runs/8202229211

thomas-fossati commented 1 year ago

it looks like there is a missing mkdir -p $(BUNDLE_PATH) before lib/deps.mk:99

martinthomson commented 1 year ago

This is far, far more complicated than it seems, unfortunately.

It seems like I made an error when I put the installation of the tools identified in requirements.txt or Gemfile under /tmp. That directory is not preserved between steps in the build (I thought it would be, but it seems like it can be lost between steps). I have a test fix in place, but I want to ensure that it works first. See the ci-cache directory for a set of possible changes. Some of those include changes to your workflow files. That won't affect correctness, but it will affect performance. As that's on me, I'll send you (and maybe others) a PR when I'm happy that it works.

martinthomson commented 1 year ago

OK, I think that I've fixed this up, so you should be able to run another build. I'll send you a pull request (and maybe a few others who might have similar issues).

martinthomson commented 1 year ago

Closing this. Let me know if anything doesn't work out for you.

thomas-fossati commented 1 year ago

Closing this. Let me know if anything doesn't work out for you.

It worked. Thanks a lot!