Skip to content

Run as Docker container#6

Merged
Code0x58 merged 3 commits intoCode0x58:masterfrom
comedian780:master
Sep 19, 2019
Merged

Run as Docker container#6
Code0x58 merged 3 commits intoCode0x58:masterfrom
comedian780:master

Conversation

@comedian780
Copy link
Copy Markdown
Contributor

With the Dockerfile you can build gitlab-ci-validate as Docker image.
Since the image has a size of 6.57MB (uncompressed) it might be pretty useful to test your template files in a CI pipeline.

Copy link
Copy Markdown
Owner

@Code0x58 Code0x58 left a comment

Choose a reason for hiding this comment

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

Thanks! I'll look at publishing an image automatically from GitHub Actions in a few days

registry.gitlab.com/comedian780/docker-gitlab-ci-validate custom.yml .files.yaml .additional.yml
```

You can also test all YAML files inside a directory (this also includes YAML files in subdirectories):
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

I feel this is a little over-reaching as gitlab-ci-validate will reject anything not ending with .yml, and I imagine scenarios where this would be relevant would be rare

p.s. just because code golf:

find . -type f -iname \*.yml | xargs docker run -i --rm -v $PWD:/yaml registry.gitlab.com/comedian780/docker-gitlab-ci-validate

@Code0x58 Code0x58 merged commit 4e416b8 into Code0x58:master Sep 19, 2019
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