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

docs: update dos games example #2924

Merged
merged 1 commit into from
Aug 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/composable-packages/zarf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ components:
# default: false # the initial value overrides the child component
import:
# The URL to the skeleton package containing this component's package definition
url: oci://🦄/dos-games:1.0.0
url: oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0
# Example optional custom name to point to in the imported package (default is to use this component's name)
name: baseline
# Un'name'd Zarf primitives will be appended to the end of the primitive's list for that component.
Expand Down
4 changes: 2 additions & 2 deletions site/src/content/docs/getting-started/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import { Tabs, TabItem, LinkCard, CardGrid } from '@astrojs/starlight/components
# (Select optional components as desired)

# Now you are ready to deploy any Zarf Package, try out our Retro Arcade!!
zarf package deploy oci://🦄/dos-games:1.0.0 --key=https://zarf.dev/cosign.pub
zarf package deploy oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0 --key=https://zarf.dev/cosign.pub
# (Select 'Y' to confirm deployment)
```

Expand All @@ -39,7 +39,7 @@ import { Tabs, TabItem, LinkCard, CardGrid } from '@astrojs/starlight/components
zarf init --confirm

# Deploy the DOS Games package
zarf package deploy oci://🦄/dos-games:1.0.0 \
zarf package deploy oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0 \
--key=https://zarf.dev/cosign.pub \
--confirm
```
Expand Down
2 changes: 1 addition & 1 deletion src/test/e2e/09_component_compose_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func (suite *CompositionSuite) Test_0_ComposabilityExample() {

// Ensure that the action was appended
suite.Contains(stdErr, `
- defenseunicorns/zarf-game:multi-tile-dark
- ghcr.io/zarf-dev/doom-game:0.0.1
actions:
onDeploy:
before:
Expand Down
4 changes: 2 additions & 2 deletions src/test/e2e/12_lint_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,14 @@ func TestLint(t *testing.T) {
// Testing import / compose + variables are working
require.Contains(t, strippedStderr, ".components.[2].images.[3] | Image not pinned with digest - busybox:latest")
// Testing OCI imports get linted
require.Contains(t, strippedStderr, ".components.[0].images.[0] | Image not pinned with digest - defenseunicorns/zarf-game:multi-tile-dark")
require.Contains(t, strippedStderr, ".components.[0].images.[0] | Image not pinned with digest - ghcr.io/zarf-dev/doom-game:0.0.1")

// Check flavors
require.NotContains(t, strippedStderr, "image-in-bad-flavor-component:unpinned")
require.Contains(t, strippedStderr, "image-in-good-flavor-component:unpinned")

// Check reported filepaths
require.Contains(t, strippedStderr, "Linting package \"dos-games\" at oci://🦄/dos-games:1.0.0")
require.Contains(t, strippedStderr, "Linting package \"dos-games\" at oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0")
require.Contains(t, strippedStderr, fmt.Sprintf("Linting package \"lint\" at %s", testPackagePath))
})
}
6 changes: 3 additions & 3 deletions src/test/e2e/27_deploy_regression_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ func TestGHCRDeploy(t *testing.T) {
// shas for package published 2023-08-08T22:13:51Z
switch e2e.Arch {
case "arm64":
sha = "ac7d7684ca9b4edb061a7732aefc17cfb7b7c983fec23e1fe319cf535618a8b6"
sha = "844dff9aa60345c67b597d5315db5e263cbda01b50643a8d0b7f5ec721f8a16f"
case "amd64":
sha = "aca4d4cf24532d69a8941a446067fc3d8474581507236b37bb7188836d93bf89"
sha = "a44d17160cd6ce7b7b6d4687e7d3f75dad4fedba6670c79665af2e8665a7868e"
}

// Test with command from https://docs.zarf.dev/getting-started/install/
stdOut, stdErr, err := e2e.Zarf(t, "package", "deploy", fmt.Sprintf("oci://🦄/dos-games:1.0.0-%s@sha256:%s", e2e.Arch, sha), "--key=https://raw.githubusercontent.com/zarf-dev/zarf/v0.38.2/cosign.pub", "--confirm")
stdOut, stdErr, err := e2e.Zarf(t, "package", "deploy", fmt.Sprintf("oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0@sha256:%s", sha), "--key=https://zarf.dev/cosign.pub", "--confirm")
require.NoError(t, err, stdOut, stdErr)

stdOut, stdErr, err = e2e.Zarf(t, "package", "remove", "dos-games", "--confirm")
Expand Down
2 changes: 1 addition & 1 deletion src/test/packages/12-lint/linted-import/zarf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ components:

- name: oci-games-url
import:
url: oci://🦄/dos-games:1.0.0
url: oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0
name: baseline
2 changes: 1 addition & 1 deletion src/test/packages/12-lint/zarf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ components:

- name: oci-games-url
import:
url: oci://🦄/dos-games:1.0.0
url: oci://ghcr.io/zarf-dev/packages/dos-games:1.1.0
name: baseline

- name: oci-games-url
Expand Down