-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into auto-scripts
- Loading branch information
Showing
28 changed files
with
2,423 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
------------------------------------------------------------------- | ||
Tru Oct 17 21:58:46 UTC 2024 - WesfunOfficial <[email protected]> | ||
|
||
- Added Slowroll to the product list (gh#agama-project/agama#1674) | ||
|
||
------------------------------------------------------------------- | ||
Thu Oct 17 08:16:42 UTC 2024 - Ladislav Slezák <[email protected]> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,143 @@ | ||
id: Slowroll | ||
name: Slowroll | ||
# ------------------------------------------------------------------------------ | ||
# WARNING: When changing the product description delete the translations located | ||
# at the at translations/description key below to avoid using obsolete | ||
# translations!! | ||
# ------------------------------------------------------------------------------ | ||
description: 'A slightly slower rolling release of openSUSE designed to update | ||
less often than Tumbleweed but more often than Leap without forcing users to | ||
choose between "stable" and newer packages' | ||
icon: Slowroll.svg | ||
# Do not manually change any translations! See README.md for more details. | ||
translations: | ||
software: | ||
installation_repositories: | ||
- url: https://download.opensuse.org/slowroll/repo/oss/ | ||
archs: x86_64 | ||
- url: https://download.opensuse.org/slowroll/repo/non-oss/ | ||
archs: x86_64 | ||
|
||
mandatory_patterns: | ||
- enhanced_base | ||
optional_patterns: null | ||
user_patterns: | ||
- basic-desktop | ||
- gnome | ||
- kde | ||
- yast2_basis | ||
- yast2_desktop | ||
- yast2_server | ||
- multimedia | ||
- office | ||
mandatory_packages: | ||
- NetworkManager | ||
- openSUSE-repos-Slowroll | ||
optional_packages: null | ||
base_product: openSUSE | ||
|
||
security: | ||
lsm: apparmor | ||
available_lsms: | ||
apparmor: | ||
patterns: | ||
- apparmor | ||
selinux: | ||
patterns: | ||
- selinux | ||
policy: enforcing | ||
none: | ||
patterns: null | ||
|
||
storage: | ||
space_policy: delete | ||
volumes: | ||
- "/" | ||
- "swap" | ||
volume_templates: | ||
- mount_path: "/" | ||
filesystem: btrfs | ||
btrfs: | ||
snapshots: true | ||
read_only: false | ||
default_subvolume: "0" | ||
subvolumes: | ||
- path: home | ||
- path: opt | ||
- path: root | ||
- path: srv | ||
- path: usr/local | ||
# Unified var subvolume - https://lists.opensuse.org/opensuse-packaging/2017-11/msg00017.html | ||
- path: var | ||
copy_on_write: false | ||
# Architecture specific subvolumes | ||
- path: boot/grub2/arm64-efi | ||
archs: aarch64 | ||
- path: boot/grub2/arm-efi | ||
archs: arm | ||
- path: boot/grub2/i386-pc | ||
archs: x86_64 | ||
- path: boot/grub2/powerpc-ieee1275 | ||
archs: ppc,!board_powernv | ||
- path: boot/grub2/s390x-emu | ||
archs: s390 | ||
- path: boot/grub2/x86_64-efi | ||
archs: x86_64 | ||
- path: boot/grub2/riscv64-efi | ||
archs: riscv64 | ||
size: | ||
auto: true | ||
outline: | ||
required: true | ||
filesystems: | ||
- btrfs | ||
- ext2 | ||
- ext3 | ||
- ext4 | ||
- xfs | ||
auto_size: | ||
base_min: 5 GiB | ||
base_max: 15 GiB | ||
snapshots_increment: 250% | ||
max_fallback_for: | ||
- "/home" | ||
snapshots_configurable: true | ||
- mount_path: "swap" | ||
filesystem: swap | ||
size: | ||
auto: true | ||
outline: | ||
auto_size: | ||
base_min: 1 GiB | ||
base_max: 2 GiB | ||
adjust_by_ram: true | ||
required: false | ||
filesystems: | ||
- swap | ||
- mount_path: "/home" | ||
filesystem: xfs | ||
size: | ||
auto: false | ||
min: 10 GiB | ||
max: unlimited | ||
outline: | ||
required: false | ||
filesystems: | ||
- btrfs | ||
- ext2 | ||
- ext3 | ||
- ext4 | ||
- xfs | ||
- filesystem: xfs | ||
size: | ||
auto: false | ||
min: 1 GiB | ||
outline: | ||
required: false | ||
filesystems: | ||
- btrfs | ||
- ext2 | ||
- ext3 | ||
- ext4 | ||
- xfs | ||
- vfat |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# frozen_string_literal: true | ||
|
||
# Copyright (c) [2024] SUSE LLC | ||
# | ||
# All Rights Reserved. | ||
# | ||
# This program is free software; you can redistribute it and/or modify it | ||
# under the terms of version 2 of the GNU General Public License as published | ||
# by the Free Software Foundation. | ||
# | ||
# This program is distributed in the hope that it will be useful, but WITHOUT | ||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
# more details. | ||
# | ||
# You should have received a copy of the GNU General Public License along | ||
# with this program; if not, contact SUSE LLC. | ||
# | ||
# To contact SUSE LLC about this file by physical or electronic mail, you may | ||
# find current contact information at www.suse.com. | ||
|
||
require "agama/storage/config_conversions/to_json_conversions/config" | ||
|
||
module Agama | ||
module Storage | ||
module ConfigConversions | ||
# Config conversion to JSON hash according to schema. | ||
class ToJSON | ||
# @param config [Storage::Config] | ||
def initialize(config) | ||
@config = config | ||
end | ||
|
||
# Performs the conversion to Hash according to the JSON schema. | ||
# | ||
# @return [Hash] | ||
def convert | ||
ToJSONConversions::Config.new(config).convert | ||
end | ||
|
||
private | ||
|
||
# @return [Storage::Config] | ||
attr_reader :config | ||
end | ||
end | ||
end | ||
end |
45 changes: 45 additions & 0 deletions
45
service/lib/agama/storage/config_conversions/to_json_conversions.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# frozen_string_literal: true | ||
|
||
# Copyright (c) [2024] SUSE LLC | ||
# | ||
# All Rights Reserved. | ||
# | ||
# This program is free software; you can redistribute it and/or modify it | ||
# under the terms of version 2 of the GNU General Public License as published | ||
# by the Free Software Foundation. | ||
# | ||
# This program is distributed in the hope that it will be useful, but WITHOUT | ||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
# more details. | ||
# | ||
# You should have received a copy of the GNU General Public License along | ||
# with this program; if not, contact SUSE LLC. | ||
# | ||
# To contact SUSE LLC about this file by physical or electronic mail, you may | ||
# find current contact information at www.suse.com. | ||
|
||
require "agama/storage/config_conversions/from_json_conversions/base" | ||
require "agama/storage/config_conversions/from_json_conversions/boot" | ||
require "agama/storage/config_conversions/from_json_conversions/config" | ||
require "agama/storage/config_conversions/from_json_conversions/drive" | ||
require "agama/storage/config_conversions/from_json_conversions/encryption" | ||
require "agama/storage/config_conversions/from_json_conversions/filesystem" | ||
require "agama/storage/config_conversions/from_json_conversions/logical_volume" | ||
require "agama/storage/config_conversions/from_json_conversions/luks1" | ||
require "agama/storage/config_conversions/from_json_conversions/luks2" | ||
require "agama/storage/config_conversions/from_json_conversions/partition" | ||
require "agama/storage/config_conversions/from_json_conversions/pervasive_luks2" | ||
require "agama/storage/config_conversions/from_json_conversions/search" | ||
require "agama/storage/config_conversions/from_json_conversions/size" | ||
require "agama/storage/config_conversions/from_json_conversions/volume_group" | ||
|
||
module Agama | ||
module Storage | ||
module ConfigConversions | ||
# Conversions to JSON. | ||
module ToJSONConversions | ||
end | ||
end | ||
end | ||
end |
74 changes: 74 additions & 0 deletions
74
service/lib/agama/storage/config_conversions/to_json_conversions/base.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
# frozen_string_literal: true | ||
|
||
# Copyright (c) [2024] SUSE LLC | ||
# | ||
# All Rights Reserved. | ||
# | ||
# This program is free software; you can redistribute it and/or modify it | ||
# under the terms of version 2 of the GNU General Public License as published | ||
# by the Free Software Foundation. | ||
# | ||
# This program is distributed in the hope that it will be useful, but WITHOUT | ||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
# more details. | ||
# | ||
# You should have received a copy of the GNU General Public License along | ||
# with this program; if not, contact SUSE LLC. | ||
# | ||
# To contact SUSE LLC about this file by physical or electronic mail, you may | ||
# find current contact information at www.suse.com. | ||
|
||
module Agama | ||
module Storage | ||
module ConfigConversions | ||
module ToJSONConversions | ||
# Base class for conversions to JSON hash according to schema. | ||
class Base | ||
# Defines the expected config type to perform the conversion. | ||
# | ||
# @raise If a subclass does not defines a type. | ||
# @return [Class] | ||
def self.config_type | ||
raise "Undefined config type" | ||
end | ||
|
||
# @param config [Object] The config type is provided by the {.config_type} method. | ||
def initialize(config) | ||
type = self.class.config_type | ||
raise "Invalid config (#{type} expected): #{config}" unless config.is_a?(type) | ||
|
||
@config = config | ||
end | ||
|
||
# Performs the conversion to Hash according to the JSON schema. | ||
# | ||
# @return [Hash, nil] | ||
def convert | ||
config_json = {} | ||
|
||
conversions.each do |property, value| | ||
next if value.nil? | ||
|
||
config_json[property] = value | ||
end | ||
|
||
config_json.empty? ? nil : config_json | ||
end | ||
|
||
private | ||
|
||
# @return [Object] The config type is provided by the {.config_type} method. | ||
attr_reader :config | ||
|
||
# Values to generate the JSON. | ||
# | ||
# @return [Hash] e.g., { name: "/dev/vda" }. | ||
def conversions | ||
{} | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
49 changes: 49 additions & 0 deletions
49
service/lib/agama/storage/config_conversions/to_json_conversions/boot.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# frozen_string_literal: true | ||
|
||
# Copyright (c) [2024] SUSE LLC | ||
# | ||
# All Rights Reserved. | ||
# | ||
# This program is free software; you can redistribute it and/or modify it | ||
# under the terms of version 2 of the GNU General Public License as published | ||
# by the Free Software Foundation. | ||
# | ||
# This program is distributed in the hope that it will be useful, but WITHOUT | ||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
# more details. | ||
# | ||
# You should have received a copy of the GNU General Public License along | ||
# with this program; if not, contact SUSE LLC. | ||
# | ||
# To contact SUSE LLC about this file by physical or electronic mail, you may | ||
# find current contact information at www.suse.com. | ||
|
||
require "agama/storage/config_conversions/to_json_conversions/base" | ||
require "agama/storage/configs/logical_volume" | ||
|
||
module Agama | ||
module Storage | ||
module ConfigConversions | ||
module ToJSONConversions | ||
# Boot conversion to JSON hash according to schema. | ||
class Boot < Base | ||
# @see Base | ||
def self.config_type | ||
Configs::Boot | ||
end | ||
|
||
private | ||
|
||
# @see Base#conversions | ||
def conversions | ||
{ | ||
configure: config.configure?, | ||
device: config.device | ||
} | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
Oops, something went wrong.