Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Builds are not triggered on main branch so container image isn't produced #940

Closed
jsturtevant opened this issue Feb 15, 2022 · 4 comments · Fixed by #945 or #948
Closed

Builds are not triggered on main branch so container image isn't produced #940

jsturtevant opened this issue Feb 15, 2022 · 4 comments · Fixed by #945 or #948
Assignees

Comments

@jsturtevant
Copy link
Contributor

In #864 some logic was added to build a "bleeding edge" container:

- name: Push Latest image
if: ${{ github.event_name != 'pull_request' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
VERSION=latest make push-all

This doesn't trigger currently because the workflow only runs on PR's and tags:

on:
pull_request:
branches:
- master
release:
types:
- published
- edited

Adding a trigger like

on:
  push:
    branches: [ master ]

would build, test and then push the bleeding edge image as well give a signal that main branch is healthy after the PR merge. @breed808 @carlpett any thoughts on this?

@breed808
Copy link
Contributor

Agreed, we'll need to enable CI for pushes to master to get this working.

@breed808
Copy link
Contributor

master CI job is failing when attempting to build container images. Will need to investigate and resolve.

docker build --build-arg=BASE=mcr.microsoft.com/windows/nanoserver:1809 -f Dockerfile -t ghcr.io/prometheus-community/windows-exporter:0.18.2+11-1809 .
invalid argument "ghcr.io/prometheus-community/windows-exporter:0.18.2+11-1809" for "-t, --tag" flag: invalid reference format
See 'docker build --help'.

@breed808 breed808 reopened this Feb 27, 2022
@breed808
Copy link
Contributor

breed808 commented Feb 27, 2022

I think the plus ('+') in the tag name is causing the failure. From the docker documentation:

A tag name must be valid ASCII and may contain lowercase and uppercase letters, digits, underscores, periods and dashes. A tag name may not start with a period or a dash and may contain a maximum of 128 characters.

@jsturtevant
Copy link
Contributor Author

Thanks for working through the fixes! Sorry these slipped through my testing.

Looks like the image is available now: https://github.com/prometheus-community/windows_exporter/pkgs/container/windows-exporter 🥳

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 a pull request may close this issue.

2 participants