Skip to content

Commit

Permalink
Merge pull request #7952 from jordimassaguerpla/ci_use_released_conta…
Browse files Browse the repository at this point in the history
…inerized_server

CI: for gh actions, use the uyuni containerized server
  • Loading branch information
jordimassaguerpla authored Jan 30, 2024
2 parents 1565c16 + 0bebb7e commit 3987295
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 104 deletions.
34 changes: 2 additions & 32 deletions .github/workflows/build_containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,37 +7,7 @@ env:
IMAGE_NAME: ${{ github.repository }}

jobs:
build-and-push-server-all-in-one-image:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Log in to the Container registry
uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}/ci-test-server-all-in-one

- name: Build and push Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: ./testsuite/dockerfiles/server-all-in-one/
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-and-push-server-all-in-one-dev-image:
needs: build-and-push-server-all-in-one-image
runs-on: ubuntu-latest
permissions:
contents: read
Expand Down Expand Up @@ -67,8 +37,8 @@ jobs:
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-args: |
BASE=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}/ci-test-server-all-in-one
VERSION=master
BASE=registry.opensuse.org/uyuni/server
VERSION=2023.12
build-and-push-ubuntu-minion-image:
runs-on: ubuntu-latest
permissions:
Expand Down
35 changes: 0 additions & 35 deletions testsuite/dockerfiles/server-all-in-one/Dockerfile

This file was deleted.

11 changes: 0 additions & 11 deletions testsuite/dockerfiles/server-all-in-one/etc_pam.d_sshd

This file was deleted.

24 changes: 0 additions & 24 deletions testsuite/dockerfiles/server-all-in-one/setup_env.sh

This file was deleted.

2 changes: 1 addition & 1 deletion testsuite/podman_runner/07_start_server.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set -xe
src_dir=$(cd $(dirname "$0")/../.. && pwd -P)

sudo -i podman run --rm \
sudo -i podman run --cap-add AUDIT_CONTROL --rm \
--tmpfs /run \
-v ${src_dir}/schema/spacewalk/spacewalk-schema-upgrade:/usr/bin/spacewalk-schema-upgrade \
-v ${src_dir}/testsuite:/testsuite \
Expand Down
2 changes: 1 addition & 1 deletion testsuite/podman_runner/08_manager_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -xe
src_dir=$(cd $(dirname "$0")/../.. && pwd -P)

sudo -i podman exec uyuni-server-all-in-one-test bash -c "/testsuite/podman_runner/provide-db-schema.sh"
sudo -i podman exec uyuni-server-all-in-one-test bash -c "/usr/lib/susemanager/bin/mgr-setup -l /var/log/susemanager_setup.log -s"
sudo -i podman exec -e CERT_O="test_org" -e CERT_OU="test_ou" -e CERT_CITY="test_city" -e CERT_STATE="test_state" -e CERT_COUNTRY="DE" -e CERT_EMAIL="[email protected]" -e CERT_CNAMES="uyuni-server-all-in-one-test" -e CERT_PASS="spacewalk" -e UYUNI_FQDN="uyuni-server-all-in-one-test" -e MANAGER_USER="admin" -e MANAGER_PASS="spacewalk" -e MANAGER_ADMIN_EMAIL="[email protected]" -e MANAGER_MAIL_FROM="[email protected]" -e MANAGER_ENABLE_TFTP="n" -e MANAGER_DB_NAME="manager" -e MANAGER_DB_HOST="localhost" -e MANAGER_DB_PORT="5432" -e MANAGER_DB_USER="manager" -e MANAGER_DB_PASS="manager" -e MANAGER_DB_PROTOCOL="TCP" -e REPORT_DB_NAME="reportdb" -e REPORT_DB_USER="pythia_susemanager" -e REPORT_DB_PASS="pythia_susemanager" -e EXTERNALDB_ADMIN_USER="" -e EXTERNALDB_ADMIN_PASS="" -e EXTERNALDB_PROVIDER="" -e ISS_PARENT="" -e ACTIVATE_SLP="" -e SCC_USER="" -e SCC_PASS="" uyuni-server-all-in-one-test bash -c "/usr/lib/susemanager/bin/mgr-setup -l /var/log/susemanager_setup.log -s"
sudo -i podman exec uyuni-server-all-in-one-test bash -c "/usr/bin/spacewalk-schema-upgrade -y"

# Make sure latest sql migration scripts have been executed for both the main and the reporting database
Expand Down

0 comments on commit 3987295

Please sign in to comment.