mirror of
https://github.com/redhat-developer/odo.git
synced 2025-10-19 03:06:19 +03:00
ci: Fix Podman job
This commit is contained in:
11
.github/workflows/ci.yaml
vendored
11
.github/workflows/ci.yaml
vendored
@@ -106,12 +106,6 @@ jobs:
|
||||
steps:
|
||||
- run: cat /etc/os-release || true
|
||||
- run: podman info
|
||||
# TODO(rm3l): workaround for https://github.com/actions/runner-images/issues/7753
|
||||
# (caused by https://bugs.launchpad.net/ubuntu/+source/libpod/+bug/2024394).
|
||||
# Remove this when this issue is fixed and available in the ubuntu runner image
|
||||
- run: |
|
||||
sudo apt install podman=3.4.4+ds1-1ubuntu1 --allow-downgrades
|
||||
podman info
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Setup Go
|
||||
@@ -133,7 +127,10 @@ jobs:
|
||||
# This is currently hard-coded because GH won't expose secrets or variables to PRs created from forks.
|
||||
# Hopefully, variables (which are non-sensible by definition) will be passed to workflows triggered by PRs from forks.
|
||||
# See https://github.com/community/community/discussions/44322
|
||||
PODMAN_EXEC_NODES: 10
|
||||
PODMAN_EXEC_NODES: 1
|
||||
# Namespacing feature removed from Podman v4.5.0: https://github.com/containers/podman/pull/17586
|
||||
# TODO(rm3l): ideally, we could separate Podman root to isolate tests and run them in parallel
|
||||
PODMAN_USE_NAMESPACES: 'false'
|
||||
run: make test-integration-podman
|
||||
- name: List and stop remaining containers
|
||||
if: ${{ always() }}
|
||||
|
||||
@@ -25,7 +25,7 @@ func getBooleanValueFromEnvVar(envvar string, defaultValue bool) bool {
|
||||
}
|
||||
|
||||
func GenerateAndSetContainersConf(dir string) {
|
||||
useNamespaces := getBooleanValueFromEnvVar("PODMAN_USE_NAMESPACES", true)
|
||||
useNamespaces := getBooleanValueFromEnvVar("PODMAN_USE_NAMESPACES", false)
|
||||
if !useNamespaces {
|
||||
return
|
||||
}
|
||||
|
||||
@@ -228,7 +228,7 @@ var _ = Describe("odo list with devfile", Label(helper.LabelSkipOnOpenShift), fu
|
||||
})
|
||||
})
|
||||
|
||||
When("dev is running on podman", Label(helper.LabelPodman), func() {
|
||||
When("dev is running on podman", Serial, Label(helper.LabelPodman), func() {
|
||||
BeforeEach(func() {
|
||||
var err error
|
||||
devSession, err = helper.StartDevMode(helper.DevSessionOpts{
|
||||
|
||||
@@ -142,9 +142,9 @@ var _ = Describe("odo generic", Label(helper.LabelSkipOnOpenShift), func() {
|
||||
Expect(odoVersion).To(ContainSubstring(helper.GetPodmanVersion()))
|
||||
} else {
|
||||
Expect(odoVersion).Should(MatchRegexp(reKubernetesVersion))
|
||||
serverURL := oc.GetCurrentServerURL()
|
||||
Expect(odoVersion).Should(ContainSubstring("Server: " + serverURL))
|
||||
if !helper.IsKubernetesCluster() {
|
||||
serverURL := oc.GetCurrentServerURL()
|
||||
Expect(odoVersion).Should(ContainSubstring("Server: " + serverURL))
|
||||
ocpMatcher := ContainSubstring("OpenShift: ")
|
||||
if serverVersion := commonVar.CliRunner.GetVersion(); serverVersion == "" {
|
||||
// Might indicate a user permission error on certain clusters (observed with a developer account on Prow nightly jobs)
|
||||
@@ -164,9 +164,9 @@ var _ = Describe("odo generic", Label(helper.LabelSkipOnOpenShift), func() {
|
||||
helper.JsonPathSatisfiesAll(odoVersion, "podman.client.version", MatchRegexp(reJSONVersion), Equal(helper.GetPodmanVersion()))
|
||||
} else {
|
||||
helper.JsonPathSatisfiesAll(odoVersion, "cluster.kubernetes.version", MatchRegexp(reJSONVersion))
|
||||
serverURL := oc.GetCurrentServerURL()
|
||||
helper.JsonPathContentIs(odoVersion, "cluster.serverURL", serverURL)
|
||||
if !helper.IsKubernetesCluster() {
|
||||
serverURL := oc.GetCurrentServerURL()
|
||||
helper.JsonPathContentIs(odoVersion, "cluster.serverURL", serverURL)
|
||||
m := BeEmpty()
|
||||
if serverVersion := commonVar.CliRunner.GetVersion(); serverVersion != "" {
|
||||
// A blank serverVersion might indicate a user permission error on certain clusters (observed with a developer account on Prow nightly jobs)
|
||||
|
||||
Reference in New Issue
Block a user