Skip to content

Commit

Permalink
add buildstamp script, funny stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
korewaChino committed Oct 22, 2023
1 parent 505bd27 commit 1756a1a
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
3 changes: 3 additions & 0 deletions katsu/modules/base/base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ scripts:
- id: selinux-setup
name: Set up SELinux
file: selinux.sh
- id: buildstamp
name: Generate buildstamp
file: buildstamp.sh

dnf:
releasever: 39
Expand Down
24 changes: 24 additions & 0 deletions katsu/modules/base/buildstamp.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash -x

# get data from /etc/os-release

source /etc/os-release


# get date in form of example 202112022224
DATE=$(date +%Y%m%d%H%M)

UUID="${DATE}.$(uname -m)"

# Inject a dummy .buildstamp so Anaconda doesn't complain
cat << EOF > /.buildstamp
[Main]
Product=${NAME}
Version=${VERSION}
BugURL=${BUG_REPORT_URL}
IsFinal=true
UUID=$UUID
Variant=${VARIANT_ID}
[Compose]
Katsu=0.1
EOF

0 comments on commit 1756a1a

Please sign in to comment.