mirror of
https://github.com/winesapOS/winesapOS.git
synced 2025-08-01 06:59:13 +00:00
[install][tests][upgrade][uninstall][github_actions] Use winesapOS rolling upgrades
repository instead of the stable repository by default. Resolves #1072
This commit is contained in:
parent
49e79d72bd
commit
e686552eb0
12 changed files with 48 additions and 27 deletions
2
.github/workflows/image-arch-linux.yml
vendored
2
.github/workflows/image-arch-linux.yml
vendored
|
@ -42,4 +42,4 @@ jobs:
|
|||
run: docker build --pull --no-cache -t winesapos-img-builder build/.
|
||||
- name: Build system image
|
||||
id: build_image
|
||||
run: docker run --rm -v $(pwd):/workdir -v /dev:/dev --env WINESAPOS_ENABLE_TESTING_REPO=true --env WINESAPOS_DEBUG_INSTALL=true --env WINESAPOS_DEBUG_TESTS=true --env WINESAPOS_ENABLE_PORTABLE_STORAGE=false --privileged=true winesapos-img-builder:latest /bin/bash -x /workdir/scripts/winesapos-build.sh
|
||||
run: docker run --rm -v $(pwd):/workdir -v /dev:/dev --env WINESAPOS_DEBUG_INSTALL=true --env WINESAPOS_DEBUG_TESTS=true --env WINESAPOS_ENABLE_PORTABLE_STORAGE=false --privileged=true winesapos-img-builder:latest /bin/bash -x /workdir/scripts/winesapos-build.sh
|
||||
|
|
2
.github/workflows/image-manjaro.yml
vendored
2
.github/workflows/image-manjaro.yml
vendored
|
@ -44,4 +44,4 @@ jobs:
|
|||
run: docker build --pull --no-cache -t winesapos-img-builder build/.
|
||||
- name: Build system image
|
||||
id: build_image
|
||||
run: docker run --rm -v $(pwd):/workdir -v /dev:/dev --env WINESAPOS_DISTRO=manjaro --env WINESAPOS_ENABLE_TESTING_REPO=true --env WINESAPOS_DEBUG_INSTALL=true --env WINESAPOS_DEBUG_TESTS=true --env WINESAPOS_ENABLE_PORTABLE_STORAGE=false --privileged=true winesapos-img-builder:latest /bin/bash -x /workdir/scripts/winesapos-build.sh
|
||||
run: docker run --rm -v $(pwd):/workdir -v /dev:/dev --env WINESAPOS_DISTRO=manjaro --env WINESAPOS_DEBUG_INSTALL=true --env WINESAPOS_DEBUG_TESTS=true --env WINESAPOS_ENABLE_PORTABLE_STORAGE=false --privileged=true winesapos-img-builder:latest /bin/bash -x /workdir/scripts/winesapos-build.sh
|
||||
|
|
|
@ -36,7 +36,7 @@ jobs:
|
|||
run: mkdir output && chmod 777 output
|
||||
- name: Build winesapOS testing repository
|
||||
id: build_repo_testing
|
||||
run: docker run --name winesapos-build-repo --rm --env WINESAPOS_REPO_BUILD_TESTING=true --volume "$(pwd)/output":/output ekultails/winesapos-build-repo:latest &> /dev/stdout | tee ./output/winesapos-build-repo_$(date --iso-8601=seconds).log
|
||||
run: docker run --name winesapos-build-repo --rm --env WINESAPOS_REPO_BUILD_ROLLING=true --volume "$(pwd)/output":/output ekultails/winesapos-build-repo:latest &> /dev/stdout | tee ./output/winesapos-build-repo_$(date --iso-8601=seconds).log
|
||||
- name: Check status code
|
||||
# Provide the return code without actually exiting.
|
||||
run: (exit $(cat ./output/winesapos-build-repo_exit-code.txt))
|
||||
|
@ -61,8 +61,8 @@ jobs:
|
|||
SSH_KEY: ${{ secrets.REPO_SSH_KEY }}
|
||||
SSH_HOST: ${{ secrets.REPO_SSH_HOST }}
|
||||
- name: Back up old repository files
|
||||
run: ssh repo "mv /data/winesapos-repo/repo/winesapos-testing /data/winesapos-repo/repo/winesapos-testing_$(date --iso-8601=seconds)"
|
||||
run: ssh repo "mv /data/winesapos-repo/repo/winesapos-rolling /data/winesapos-repo/repo/winesapos-rolling_$(date --iso-8601=seconds)"
|
||||
- name: Create new repository folder
|
||||
run: ssh repo "mkdir -p /data/winesapos-repo/repo/winesapos-testing/x86_64"
|
||||
run: ssh repo "mkdir -p /data/winesapos-repo/repo/winesapos-rolling/x86_64"
|
||||
- name: Copy the new repository over to the server
|
||||
run: rsync -avurP ./output/ repo:/data/winesapos-repo/repo/winesapos-testing/x86_64/
|
||||
run: rsync -avurP ./output/ repo:/data/winesapos-repo/repo/winesapos-rolling/x86_64/
|
|
@ -18,6 +18,7 @@
|
|||
- Add GIMP for photo editing.
|
||||
- Add mpv for HDR video playback.
|
||||
- Add ckb-next for supporting RGB on Corsair keyboards and mice.
|
||||
- Change winesapOS testing repository to be a rolling updates repository.
|
||||
|
||||
## 4.3.0 - The Wayland Update
|
||||
|
||||
|
|
|
@ -304,7 +304,7 @@ $ export <KEY>=<VALUE>
|
|||
| --- | ------ | --------------------------- | ------------ | ------------- | ----------- |
|
||||
| WINESAPOS_DEBUG_INSTALL | true or false | true | true | true | Use `set -x` for debug shell logging during the installation. |
|
||||
| WINESAPOS_DEBUG_TESTS | true or false | false | false | false | Use `set -x` for debug shell logging during the tests. |
|
||||
| WINESAPOS_ENABLE_TESTING_REPO | true or false | false | false | false | Use the `[winesapos-testing]` repository instead of the stable `[winesapos]` repository during the installation. |
|
||||
| WINESAPOS_ENABLE_REPO_ROLLING | true or false | true | true | true | Use the `[winesapos-rolling]` repository instead of the stable `[winesapos]` repository during the installation. |
|
||||
| WINESAPOS_BUILD_IN_VM_ONLY | true or false | true | true | true | If the build should fail and exit if it is not in a virtual machine. Set to `false` for a bare-metal installation. |
|
||||
| WINESAPOS_CREATE_DEVICE | true or false | false | false | false | If the build should create and use an image file instead of using an existing block device. |
|
||||
| WINESAPOS_CREATE_DEVICE_SIZE | integer for GiB | (None) | (None) | (None) | Manually override the default values for the device size (8 GiB with no cross-platform storage and 25 GiB with). |
|
||||
|
@ -464,7 +464,9 @@ sudo docker build --pull --no-cache -t winesapos-img-builder:manjaro build/.
|
|||
sudo docker run --rm -v $(pwd):/workdir -v /dev:/dev --env WINESAPOS_DISTRO=manjaro --privileged=true winesapos-img-builder:manjaro /bin/bash -x /workdir/scripts/winesapos-build.sh
|
||||
```
|
||||
|
||||
By default, the performance image is built. Use `--env WINESAPOS_ENV_FILE=winesapos-env-minimal.sh` or `--env WINESAPOS_ENV_FILE=winesapos-env-secure.sh` to build a different image type. Use the winesapOS testing repository with the argument `--env WINESAPOS_ENABLE_TESTING_REPO=true`.
|
||||
For a new stable release, use the winesapOS repository repository with the argument `--env WINESAPOS_ENABLE_REPO_ROLLING=false`.
|
||||
|
||||
By default, the performance image is built. Use `--env WINESAPOS_ENV_FILE=winesapos-env-minimal.sh` or `--env WINESAPOS_ENV_FILE=winesapos-env-secure.sh` to build a different image type.
|
||||
|
||||
Optionally do a build using the Arch Linux Archive (ALA) by using `--env WINESAPOS_SINGLE_MIRROR=true --env WINESAPOS_SINGLE_MIRROR_URL=https://archive.archlinux.org/repos/2024/08/12`. Manjaro does not have an ALA equivalent.
|
||||
|
||||
|
@ -527,12 +529,17 @@ Manual tests for each image type:
|
|||
|
||||
##### Upgrades
|
||||
|
||||
By default, the winesapOS upgrade script will update all upgrade files and exit if there are changes detected. For testing on a branch that is not `stable` (such as `staging`), set an environment variable to skip updating upgrade files as these are pulled from the `stable` branch.
|
||||
Optionally set environmnet variables first.
|
||||
|
||||
| Key | Values | Default | Description |
|
||||
| --- | ------ | ------- | ----------- |
|
||||
| WINESAPOS_UPGRADE_FILES | true or false | true | Replace the remote upgrade desktop shortcut and script with newer versions if they are older. |
|
||||
| WINESAPOS_UPGRADE_REPO_ROLLING | true or false | true | Use the winesapOS rolling updates package repository instead of the stable package repository. |
|
||||
| WINESAPOS_UPGRADE_VERSION_CHECK | true or false | false | Only upgrade if a newer version is available. |
|
||||
|
||||
Then run the upgrade script.
|
||||
|
||||
```
|
||||
export WINESAPOS_UPGRADE_FILES=false
|
||||
export WINESAPOS_UPGRADE_TESTING_REPO=true
|
||||
export WINESAPOS_UPGRADE_VERSION_CHECK=false
|
||||
curl https://raw.githubusercontent.com/winesapOS/winesapOS/staging/scripts/winesapos-upgrade.sh | sudo -E bash
|
||||
```
|
||||
|
||||
|
@ -617,14 +624,14 @@ kubectl --namespace winesapos-repo cp <PACKAGE_FILE> deploy-winesapos-repo-<UUID
|
|||
For specialized repository builds, use environment variables to determine what packages will be built.
|
||||
|
||||
```
|
||||
sudo docker run --name winesapos-build-repo --rm --env WINESAPOS_REPO_BUILD_TESTING=true --env WINESAPOS_REPO_BUILD_LINUX_GIT=true --env WINESAPOS_REPO_BUILD_MESA_GIT=true --volume /tmp/winesapos-build-repo:/output ekultails/winesapos-build-repo:latest &> /tmp/winesapos-build-repo_$(date --iso-8601=seconds).log
|
||||
sudo docker run --name winesapos-build-repo --rm --env WINESAPOS_REPO_BUILD_ROLLING=true --env WINESAPOS_REPO_BUILD_LINUX_GIT=true --env WINESAPOS_REPO_BUILD_MESA_GIT=true --volume /tmp/winesapos-build-repo:/output ekultails/winesapos-build-repo:latest &> /tmp/winesapos-build-repo_$(date --iso-8601=seconds).log
|
||||
```
|
||||
|
||||
| Key | Values | Default | Description |
|
||||
| --- | ------ | ------- | ----------- |
|
||||
| WINESAPOS_REPO_BUILD_TESTING | true or false | false | Name the Pacman repository database as "winesapos-testing" instead of "winesapos". |
|
||||
| WINESAPOS_REPO_BUILD_LINUX_GIT | true or false | false | Build `linux-git`. |
|
||||
| WINESAPOS_REPO_BUILD_MESA_GIT | true or false | false | Build `mesa-git` and `lib32-mesa-git`. |
|
||||
| WINESAPOS_REPO_BUILD_ROLLING | true or false | false | Name the Pacman repository database as "winesapos-rolling" instead of "winesapos". |
|
||||
|
||||
#### GPG Signing
|
||||
|
||||
|
@ -699,7 +706,7 @@ Major release schedule for Arch Linux:
|
|||
These are tasks that need to happen before publishing a stable release.
|
||||
|
||||
- Rebuild all AUR packages.
|
||||
- First publish them to the `[winesapos-testing]` repository and test them via a new build.
|
||||
- First publish them to the `[winesapos-rolling]` repository and test them via a new build.
|
||||
- For the stable build and release, sign and then move these packages to the `[winesapos]` repository.
|
||||
- Update the versions for these programs by changing these variables:
|
||||
- rootfs/usr/local/bin/winesapos-ventoy-bootstrap.sh
|
||||
|
@ -731,7 +738,7 @@ These are tasks that need to happen before publishing a stable release.
|
|||
- Add change log notes to the [CHANGELOG.md](CHANGELOG.md) file.
|
||||
- Add upgrade notes to the [UPGRADES.md](CHANGELOG.md) file.
|
||||
- For a new release, update the `rootfs/usr/lib/os-release-winesapos` file in the git repository with the new `VERSION` and `VERSION_ID` before building an image.
|
||||
- Before building an alpha or beta build, enable the `[winesapos-testing]` repository with `export WINESAPOS_ENABLE_TESTING_REPO=true`.
|
||||
- Before building an alpha or beta build, enable the `[winesapos-rolling]` repository with `export WINESAPOS_ENABLE_REPO_ROLLING=true`.
|
||||
- Create a "minimal" and "performance" release image (not "secure") using a [container build](#automated-container-build).
|
||||
- Due to the "secure" image having a common LUKS container encryption key that would be shared, users are encouraged to do their own custom build of winesapOS to generate a unique key instead.
|
||||
- Make sure that no tests failed by checking the exit/return code of the installation script. It should be zero. If not, that is how many tests have failed.
|
||||
|
|
10
UPGRADES.md
10
UPGRADES.md
|
@ -1,5 +1,15 @@
|
|||
# Upgrade Notes
|
||||
|
||||
## 4.3.0 to 4.4.0
|
||||
|
||||
**Action Required:**
|
||||
|
||||
- None.
|
||||
|
||||
**No Action Required:**
|
||||
|
||||
- Change the winesapOS stable repository to be the winesapOS rolling updates repository.
|
||||
|
||||
## 4.2.0 to 4.3.0
|
||||
|
||||
**Action Required:**
|
||||
|
|
2
scripts/env/winesapos-env-defaults.sh
vendored
2
scripts/env/winesapos-env-defaults.sh
vendored
|
@ -6,7 +6,7 @@ export \
|
|||
WINESAPOS_INSTALL_DIR="${WINESAPOS_INSTALL_DIR:-/winesapos}" \
|
||||
WINESAPOS_DISTRO="${WINESAPOS_DISTRO:-arch}" \
|
||||
WINESAPOS_DISTRO_DETECTED="${winesapos_distro_detected}" \
|
||||
WINESAPOS_ENABLE_TESTING_REPO="${WINESAPOS_ENABLE_TESTING_REPO:-false}" \
|
||||
WINESAPOS_ENABLE_REPO_ROLLING="${WINESAPOS_ENABLE_REPO_ROLLING:-true}" \
|
||||
WINESAPOS_DE="${WINESAPOS_DE:-plasma}" \
|
||||
WINESAPOS_ENCRYPT="${WINESAPOS_ENCRYPT:-false}" \
|
||||
WINESAPOS_ENCRYPT_PASSWORD="${WINESAPOS_ENCRYPT_PASSWORD:-password}" \
|
||||
|
|
|
@ -117,7 +117,7 @@ makepkg_fn inputmodule-control
|
|||
#makepkg_fn aw87559-firmware
|
||||
mkdir /tmp/aw87559-firmware/
|
||||
cd /tmp/aw87559-firmware/
|
||||
curl --location --remote-name https://winesapos.lukeshort.cloud/repo/winesapos-testing/x86_64/aw87559-firmware-8.0.1.10-1-x86_64.pkg.tar.zst
|
||||
curl --location --remote-name https://winesapos.lukeshort.cloud/repo/winesapos-4.3.0//x86_64/aw87559-firmware-8.0.1.10-1-x86_64.pkg.tar.zst
|
||||
makepkg_local_fn noop
|
||||
|
||||
git clone https://github.com/TheoBrigitte/pkgbuilds.git
|
||||
|
@ -160,9 +160,9 @@ if [[ "${WINESAPOS_REPO_BUILD_MESA_GIT}" == "true" ]]; then
|
|||
fi
|
||||
|
||||
# Build Pacman repository metadata.
|
||||
WINESAPOS_REPO_BUILD_TESTING="${WINESAPOS_REPO_BUILD_TESTING:-false}"
|
||||
if [[ "${WINESAPOS_REPO_BUILD_TESTING}" == "true" ]]; then
|
||||
if ! repo-add "${OUTPUT_DIR}"/winesapos-testing.db.tar.gz "${OUTPUT_DIR}"/*pkg.tar.xz "${OUTPUT_DIR}"/*pkg.tar.zst; then
|
||||
WINESAPOS_REPO_BUILD_ROLLING="${WINESAPOS_REPO_BUILD_ROLLING:-false}"
|
||||
if [[ "${WINESAPOS_REPO_BUILD_ROLLING}" == "true" ]]; then
|
||||
if ! repo-add "${OUTPUT_DIR}"/winesapos-rolling.db.tar.gz "${OUTPUT_DIR}"/*pkg.tar.xz "${OUTPUT_DIR}"/*pkg.tar.zst; then
|
||||
# shellcheck disable=SC2003
|
||||
failed_builds=$(expr ${failed_builds} + 1)
|
||||
fi
|
||||
|
|
|
@ -285,12 +285,12 @@ else
|
|||
fi
|
||||
|
||||
echo "Adding the winesapOS repository..."
|
||||
if [[ "${WINESAPOS_ENABLE_TESTING_REPO}" == "false" ]]; then
|
||||
if [[ "${WINESAPOS_ENABLE_REPO_ROLLING}" == "false" ]]; then
|
||||
# shellcheck disable=SC2016
|
||||
sed -i 's/\[core]/[winesapos]\nServer = http:\/\/winesapos.lukeshort.cloud\/repo\/$repo\/$arch\n\n[core]/g' "${WINESAPOS_INSTALL_DIR}"/etc/pacman.conf
|
||||
else
|
||||
# shellcheck disable=SC2016
|
||||
sed -i 's/\[core]/[winesapos-testing]\nServer = http:\/\/winesapos.lukeshort.cloud\/repo\/$repo\/$arch\nSigLevel = Never\n\n[core]/g' "${WINESAPOS_INSTALL_DIR}"/etc/pacman.conf
|
||||
sed -i 's/\[core]/[winesapos-rolling]\nServer = http:\/\/winesapos.lukeshort.cloud\/repo\/$repo\/$arch\nSigLevel = Never\n\n[core]/g' "${WINESAPOS_INSTALL_DIR}"/etc/pacman.conf
|
||||
fi
|
||||
|
||||
# DNS resolvers need to be configured first before accessing the GPG key server.
|
||||
|
|
|
@ -245,14 +245,14 @@ printf "Testing user creation complete.\n\n"
|
|||
echo "Testing package repositories..."
|
||||
|
||||
printf "\tChecking that the winesapOS repository was added..."
|
||||
if [[ "${WINESAPOS_ENABLE_TESTING_REPO}" == "false" ]]; then
|
||||
if [[ "${WINESAPOS_ENABLE_REPO_ROLLING}" == "false" ]]; then
|
||||
if grep -q -P "^\[winesapos\]" "${WINESAPOS_INSTALL_DIR}"/etc/pacman.conf; then
|
||||
echo PASS
|
||||
else
|
||||
winesapos_test_failure
|
||||
fi
|
||||
else
|
||||
if grep -q -P "^\[winesapos-testing\]" "${WINESAPOS_INSTALL_DIR}"/etc/pacman.conf; then
|
||||
if grep -q -P "^\[winesapos-rolling\]" "${WINESAPOS_INSTALL_DIR}"/etc/pacman.conf; then
|
||||
echo PASS
|
||||
else
|
||||
winesapos_test_failure
|
||||
|
|
|
@ -5,6 +5,7 @@ exec > >(tee /root/winesapos-uninstall.log) 2>&1
|
|||
|
||||
# Remove winesapOS and SteamOS repositories.
|
||||
crudini --del /etc/pacman.conf winesapos
|
||||
crudini --del /etc/pacman.conf winesapos-rolling
|
||||
crudini --del /etc/pacman.conf winesapos-testing
|
||||
crudini --del /etc/pacman.conf jupiter
|
||||
crudini --del /etc/pacman.conf holo
|
||||
|
|
|
@ -7,6 +7,7 @@ exec > >(tee "/tmp/upgrade_${START_TIME}.log") 2>&1
|
|||
echo "Start time: ${START_TIME}"
|
||||
|
||||
WINESAPOS_UPGRADE_FILES="${WINESAPOS_UPGRADE_FILES:-true}"
|
||||
WINESAPOS_UPGRADE_REPO_ROLLING="${WINESAPOS_UPGRADE_REPO_ROLLING:-true}"
|
||||
WINESAPOS_UPGRADE_VERSION_CHECK="${WINESAPOS_UPGRADE_VERSION_CHECK:-false}"
|
||||
|
||||
# Check for a custom user name. Default to 'winesap'.
|
||||
|
@ -358,10 +359,11 @@ sudo -E -u "${WINESAPOS_USER_NAME}" "${qdbus_cmd}" "${kdialog_dbus}" /ProgressDi
|
|||
|
||||
echo "Adding the winesapOS repository..."
|
||||
crudini_wrapper --del /etc/pacman.conf winesapos
|
||||
crudini_wrapper --del /etc/pacman.conf winesapos-rolling
|
||||
crudini_wrapper --del /etc/pacman.conf winesapos-testing
|
||||
if [[ "${WINESAPOS_UPGRADE_TESTING_REPO}" == "true" ]]; then
|
||||
if [[ "${WINESAPOS_UPGRADE_REPO_ROLLING}" == "true" ]]; then
|
||||
# shellcheck disable=SC2016
|
||||
sed -i 's/\[core]/[winesapos-testing]\nServer = https:\/\/winesapos.lukeshort.cloud\/repo\/$repo\/$arch\nSigLevel = Never\n\n[core]/g' /etc/pacman.conf
|
||||
sed -i 's/\[core]/[winesapos-rolling]\nServer = https:\/\/winesapos.lukeshort.cloud\/repo\/$repo\/$arch\nSigLevel = Never\n\n[core]/g' /etc/pacman.conf
|
||||
else
|
||||
# shellcheck disable=SC2016
|
||||
sed -i 's/\[core]/[winesapos]\nServer = https:\/\/winesapos.lukeshort.cloud\/repo\/$repo\/$arch\n\n[core]/g' /etc/pacman.conf
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue