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

fix: add missing container tags #7

Closed
xynydev opened this issue Jan 22, 2024 · 13 comments · Fixed by #37
Closed

fix: add missing container tags #7

xynydev opened this issue Jan 22, 2024 · 13 comments · Fixed by #37
Assignees

Comments

@xynydev
Copy link
Member

xynydev commented Jan 22, 2024

I just built & published my image with the tool and noticed there are some differences to startingpoint with the generated tags

  • There's a commit hash tag, that's cool
    • It shouldn't need the -latest suffix, though. And another tag had latest as a prefix, hmm.
  • Major version tags are missing (38, 39)
    • Also version-date and version-commit
  • Latest date tags are named differently 20240122 (startingpoint) vs latest-20240122 (bluebuild)
@bayou-brogrammer
Copy link
Collaborator

Do we not want to include latest to just be more verbose? I always side with explicit over implicit

@gmpinder
Copy link
Member

What branch do you build on? Cause I hardcoded it to look for the live branch while I was getting it thrown together for GitHub.

@gmpinder
Copy link
Member

gmpinder commented Jan 22, 2024

Major version tags are missing (38, 39)

OH! I think it's because I'm using the version that's defined in the recipe yaml. I guess we would need to add logic to pull info from the base image to determine the proper fedora version huh?

@gmpinder gmpinder self-assigned this Jan 22, 2024
@gmpinder gmpinder changed the title feat: add missing container tags fix: add missing container tags Jan 22, 2024
@gmpinder
Copy link
Member

This seems to be tied to blue-build/github-action#2

@xynydev
Copy link
Member Author

xynydev commented Jan 23, 2024

Major version tags are missing (38, 39)

OH! I think it's because I'm using the version that's defined in the recipe yaml. I guess we would need to add logic to pull info from the base image to determine the proper fedora version huh?

Yeah, the info should be in /etc/os-release, but I'm not sure how that translates to other distros.

What branch do you build on? Cause I hardcoded it to look for the live branch while I was getting it thrown together for GitHub.

I think for new templates we want to lose the live/template branch structure, since the new reusable github action will handle all the updates in features. I'm not sure where you hardcoded this?

@xynydev
Copy link
Member Author

xynydev commented Jan 23, 2024

Ok, I found the part where live is hardcoded. Didn't know the tags were generated in template.rs. I guess you should change it to support either live or main branch to support both the old and new plans.

@gmpinder
Copy link
Member

So with Gitlab CI, they have an env var to tell your pipeline what branch is the default branch. If I can find that var for Github, that would be a good replacement

@bayou-brogrammer
Copy link
Collaborator

GitHub allows for environment variables. Go to settings, secrets/keys and it should be an environment option

@xynydev
Copy link
Member Author

xynydev commented Jan 23, 2024

Forgot to respond to this

Do we not want to include latest to just be more verbose? I always side with explicit over implicit.

I was just thinking abt how startingpoint does things and keeping parity. Another argument is: latest should always mean latest version and date-latest might be contradicting. And of course the tags always pull the latest image with that tag, that's the point. :39 is the latest version of 39, so why wouldn't :20240101 be the latest version from that date? If one wants, they could specify a different version though, like :38-20240101. But the point of :latest is to roll over to the next version automatically, so I don't see the point of :date-latest.

@gmpinder
Copy link
Member

GitHub allows for environment variables. Go to settings, secrets/keys and it should be an environment option

I was talking about the built in variables set by GitHub actions. I can look it up later

@gmpinder
Copy link
Member

gmpinder commented Feb 2, 2024

From conversations in the Discord:

  • check if branch is live or main
  • put image_version on the end of tags
  • Add a timestamp tag
  • Detect actual OS version and use that in place of recipe's image_version

@bayou-brogrammer
Copy link
Collaborator

What should the the timestamp be formatted as?

@xynydev
Copy link
Member Author

xynydev commented Feb 2, 2024

What should the the timestamp be formatted as?

Same as now, YYYYMMDD.

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.

3 participants