Skip to content

Commit

Permalink
Quadlet not Quadret
Browse files Browse the repository at this point in the history
  • Loading branch information
traylenator committed Mar 28, 2024
1 parent 84c18c8 commit 14ed721
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 7 deletions.
6 changes: 3 additions & 3 deletions REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

### Data types

* [`Podman::Quadret::Container`](#Podman--Quadret--Container): custom datatype for container entries of podman container quadlet
* [`Podman::Quadlet::Container`](#Podman--Quadlet--Container): custom datatype for container entries of podman container quadlet

## Classes

Expand Down Expand Up @@ -630,7 +630,7 @@ Default value: `undef`

##### <a name="-podman--manage_container--container_entry"></a>`container_entry`

Data type: `Optional[Podman::Quadret::Container]`
Data type: `Optional[Podman::Quadlet::Container]`

The `[Container]` section defintion.

Expand Down Expand Up @@ -1054,7 +1054,7 @@ Default value: `undef`

## Data types

### <a name="Podman--Quadret--Container"></a>`Podman::Quadret::Container`
### <a name="Podman--Quadlet--Container"></a>`Podman::Quadlet::Container`

custom datatype for container entries of podman container quadlet

Expand Down
3 changes: 1 addition & 2 deletions manifests/manage_container.pp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
Optional[Systemd::Unit::Install] $install_entry = undef,
Optional[Systemd::Unit::Unit] $unit_entry = undef,
Optional[Systemd::Unit::Service] $service_entry = undef,
Optional[Podman::Quadret::Container] $container_entry = undef,
Optional[Podman::Quadlet::Container] $container_entry = undef,
) {
assert_type(Pattern[/[a-zA-Z\-_+]+\.container/], $name)

Expand All @@ -69,7 +69,6 @@
}

if $active != undef {

$_service = regsubst($name,'(.+)\\.container','\\1.service')

service { $_service:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
require 'spec_helper'

describe 'Podman::Quadret::Container' do
describe 'Podman::Quadlet::Container' do
it { is_expected.to allow_value({ 'Image' => 'busybox' }) }
it { is_expected.to allow_value({ 'Exec' => '/bin/bash' }) }
it { is_expected.to allow_value({ 'Exec' => './entrypoint.sh' }) }
Expand Down
2 changes: 1 addition & 1 deletion types/quadret/container.pp → types/quadlet/container.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# @summary custom datatype for container entries of podman container quadlet
# @see https://docs.podman.io/en/latest/markdown/podman-systemd.unit.5.html
type Podman::Quadret::Container = Struct[
type Podman::Quadlet::Container = Struct[
Optional['AddCapability'] => Array[String[1],1],
Optional['Annotation'] => Array[String[1],1],
Optional['AutoUpdate'] => Enum['registry','local'],
Expand Down

0 comments on commit 14ed721

Please sign in to comment.