Skip to content

weekly-openshift-1-5-x #21

weekly-openshift-1-5-x

weekly-openshift-1-5-x #21

name: weekly-openshift-1-5-x
on:
pull_request:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: MicroShift OpenShift Cluster
uses: container-tools/[email protected]
#jobs:
# build:
# runs-on: ubuntu-latest
# # trying this just for fun
# steps:
# - name: Set up podman
# run: |
# source /etc/os-release
# echo "deb https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_${VERSION_ID}/ /" | sudo tee /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list
# curl -L https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_${VERSION_ID}/Release.key | sudo apt-key add -
# sudo apt-get update
# sudo apt-get -y install podman
# - name: Set up oc client
# run: |
# wget https://mirror.openshift.com/pub/openshift-v4/clients/oc/latest/linux/oc.tar.gz
# sudo tar xzvf oc.tar.gz -C /usr/local/bin
# - name: Run a microshift cluster
# run: |
# sudo podman run -d --rm --name microshift \
# --privileged -v microshift-data:/var/lib -p 6443:6443 \
# quay.io/microshift/microshift-aio:latest
# # get kubeconfig
# sudo podman exec microshift bash -c \
# 'while ! test -f "/var/lib/microshift/resources/kubeadmin/kubeconfig";
# do
# echo "Waiting for kubeconfig..."
# sleep 5
# done'
# mkdir ${HOME}/.kube
# sudo podman cp \
# microshift:/var/lib/microshift/resources/kubeadmin/kubeconfig \
# ${HOME}/.kube/config
# sudo chown ${USER} ${HOME}/.kube/config
# chmod 600 ${HOME}/.kube/config
# # wait for the cluster to become available
# sleep 10
# kubectl wait --for=condition=available apiservice --all --timeout 300s
# - name: Install helm
# uses: azure/setup-helm@fe7b79cd5ee1e45176fcad797de68ecaf3ca4814 # v4.2.0
# with:
# version: "3.9.4"
# #test to see if you can just install helm
# - run: |
# helm repo add hashicorp https://helm.releases.hashicorp.com
# helm install consul hashicorp/consul --set global.name=consul --create-namespace --namespace consul
# #- run: mkdir -p ${{ env.TEST_RESULTS }}
# - name: go mod download
# working-directory: ${{ inputs.directory }}
# run: go mod download
#
# - run: mkdir -p ${{ github.workspace }}/cli/bin
#
# # Needed by the CLI tests for doing installs
# - name: Download consul-k8s cli
# uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e # v4.1.7
# with:
# name: consul-k8s_${{ inputs.product-version }}_linux_amd64.zip
# path: ${{ github.workspace }}/cli/bin
#
# - name: Extract consul-k8s cli zip
# env:
# ZIP_LOCATION: ${{ github.workspace }}/cli/bin
# run: |
# cd "${ZIP_LOCATION}"
# unzip -j "*.zip"
#
# - name: Add consul-k8s cli to PATH
# run: echo "${{ github.workspace }}/cli/bin" >> "${GITHUB_PATH}"
# runs-on: custom-linux-xl
# steps:
# - uses: actions/checkout@v2
#
# - name: Cache CRC binary
# id: cache-crc-binary
# uses: actions/cache@v2
# with:
# path: crc
# key: ${{ runner.os }}-okd-crc
#
# - name: Download CRC binary
# run: |
# curl -LO https://dl.fedoraproject.org/pub/alt/okd-crc/macos-amd64/crc
# chmod +x crc
# sudo cp crc /usr/local/bin/crc
# crc version
#
# - name: Configure CRC
# run: |
# crc config set skip-check-root-user true
#
# - name: Setup CRC
# run: |
# crc setup
#
# - name: Start CRC
# run: |
# crc start
#
# - name: Login to CRC
# run: |
# crc oc-env
# oc login -u developer https://api.crc.testing:6443