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

1999 - Update repositories and adapt /etc/os-release to versioneer #2081

Merged
merged 4 commits into from
Dec 21, 2023

Conversation

jimmykarily
Copy link
Contributor

Add missing /etc/os-release variables to work with versioneer

Fixes #1999

Replaces #2073

@jimmykarily jimmykarily self-assigned this Dec 14, 2023
@jimmykarily jimmykarily changed the title ⬆️ Update repositories ⬆️ Update repositories and adapt /etc/os-release to versioneer Dec 14, 2023
@jimmykarily jimmykarily changed the title ⬆️ Update repositories and adapt /etc/os-release to versioneer 1999 - Update repositories and adapt /etc/os-release to versioneer Dec 14, 2023
@jimmykarily jimmykarily marked this pull request as draft December 14, 2023 15:21
@jimmykarily jimmykarily force-pushed the 1999-update-repositories-and-fix-osrelease branch from 153dac8 to e1a540f Compare December 18, 2023 11:43
Earthfile Outdated
ARG --required VARIANT
ARG --required MODEL
ARG --required BASE_IMAGE
# Uncomment if ISO_NAME is needed (the code that uses it is commented out below)
Copy link
Member

Choose a reason for hiding this comment

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

not needed anymore, we used to provide the full anme for the artifacts but we do that later in other target 👍

@@ -430,8 +419,8 @@ uki:
# Copy uki artifacts into local build dir
uki-local-artifacts:
FROM +uki
COPY +version/VERSION ./
ARG VERSION=$(cat VERSION)
COPY +git-version/GIT_VERSION ./
Copy link
Member

Choose a reason for hiding this comment

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

what is GIT_VERSION ? does that match the old VERSION?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

GIT_VERSION is just the version of kairos (with no k3s in it). It's just the result of git describe --always --tags --dirty.

Earthfile Outdated
ARG --required MODEL
ARG --required BASE_IMAGE
# +base-image will be called again by +uki but will be cached.
# We just use it here to take a shortcut to the artifact name
Copy link
Member

Choose a reason for hiding this comment

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

noice

@jimmykarily jimmykarily force-pushed the 1999-update-repositories-and-fix-osrelease branch from f0aa813 to 23bcaa6 Compare December 19, 2023 08:56
images/Dockerfile.kairos Outdated Show resolved Hide resolved
@jimmykarily jimmykarily marked this pull request as ready for review December 19, 2023 16:57
@jimmykarily jimmykarily force-pushed the 1999-update-repositories-and-fix-osrelease branch 2 times, most recently from deba8b8 to c51c392 Compare December 20, 2023 13:17
@jimmykarily
Copy link
Contributor Author

I can reproduce this failure locally: https://github.com/kairos-io/kairos/actions/runs/7276077385/job/19825149889?pr=2081
but I don't know what wrong yet.

@jimmykarily jimmykarily requested a review from a team December 20, 2023 15:25
Earthfile Outdated Show resolved Hide resolved
jimmykarily and others added 3 commits December 21, 2023 15:21
For this commit, kairos-agent has to be built from at least 4409a4e

Also:

- Remove some relics from when we had docs in this repo and when we
used to pass a VERSION to the bundle for systemd-sysext (now we use
"_ANY")
- Simplify earthly targets. They don't need all that input just to construct
  the artifact name because it's running on the "base-image".
  The artifact name is already written in the /etc/os-release file.
- Remove +version target and convert GIT_VERSION to a normal target because when you call
  `DO +foo` in a target and "foo" has "FROM myimage" in it, after the call, your
  target now runs on "myimage".

- Remove "VERSION" instances from most places, except in reusable-build-flavor
  which is using it to replace it with "latest" thus the current value
  (just the kairos version) should work. That workflow is disabled currently
  but I tried not to break it in case someone re-enables it.

Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
@mauromorales mauromorales force-pushed the 1999-update-repositories-and-fix-osrelease branch from 7e05c95 to 5c699ba Compare December 21, 2023 14:24
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
@mauromorales mauromorales merged commit ec6a6f2 into master Dec 21, 2023
34 of 35 checks passed
@mauromorales mauromorales deleted the 1999-update-repositories-and-fix-osrelease branch December 21, 2023 21:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

🐛 Adapt kairos upgrade list-releases command to handle new repositories
3 participants