Skip to content

Commit

Permalink
Merge pull request #59 from canonical/cleanup/oldScripts
Browse files Browse the repository at this point in the history
Fix CI and Housekeeping
  • Loading branch information
UtkarshBhatthere authored Aug 1, 2024
2 parents 63c54e3 + c0f7b65 commit 93391b3
Show file tree
Hide file tree
Showing 42 changed files with 30 additions and 3,367 deletions.
73 changes: 13 additions & 60 deletions .github/workflows/build_and_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,65 +32,23 @@ jobs:
name: rock
path: ${{ steps.rockcraft.outputs.rock }}

CephAdmScriptTest:
flake8-lint:
runs-on: ubuntu-latest
needs: build-rock
strategy:
matrix:
python-version: ["3.10"]

name: Lint
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- name: clean unrequired files.
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf "/usr/local/share/boost"
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: rock

- name: set up python ${{ matrix.python-version }}
- name: Check out source repository
uses: actions/checkout@v3
- name: Set up Python environment
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: install dependencies
run: |
sudo apt install skopeo
sudo python -m pip install --upgrade pip
sudo pip install flake8 pep8-naming pylxd pyyaml argparse
- name: Lint Check
run: |
flake8 . --count --show-source --statistics
python-version: "3.10"
- name: flake8 Lint
uses: py-actions/flake8@v2

- name: use local block device
run: ./test/scripts/cephadm_helper.sh use_local_disk

- name: Load image to registry
run: |
ls
rock_file=$(ls *.rock | head -1)
docker run -d -p 5000:5000 --restart=always --name registry registry:2
skopeo --insecure-policy copy oci-archive:$rock_file docker-daemon:canonical/ceph:latest
docker image ls -a
docker image tag canonical/ceph:latest localhost:5000/canonical/ceph:latest
sleep 10
docker push localhost:5000/canonical/ceph
echo $'[registries.insecure]\nregistries = ["localhost:5000"]' | sudo tee -a /etc/containers/registries.conf
- name: Deploy Cephadm over Host
run: |
sudo python test/deploy.py --osd-num 1 --direct-host 1 --ceph-version reef image "localhost:5000/canonical/ceph:latest"
CephAdmScriptLxdTest:
CephadmTest:
runs-on: ubuntu-latest
needs: build-rock
needs: [build-rock, flake8-lint]
strategy:
matrix:
python-version: ["3.10"]
Expand All @@ -116,19 +74,14 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install dependencies
run: |
sudo python -m pip install --upgrade pip
sudo pip install flake8 pep8-naming pylxd pyyaml argparse
- name: Lint Check
run: |
flake8 . --count --show-source --statistics
run: ./scripts/deploy-helper.sh install_custom_runner_dependencies

- name: Load image to registry
run: |
ls
rock_file=$(ls *.rock | head -1)
docker run -d -p 5000:5000 --restart=always --name registry registry:2
sleep 10
skopeo --insecure-policy copy oci-archive:$rock_file docker-daemon:canonical/ceph:latest
docker image ls -a
docker image tag canonical/ceph:latest localhost:5000/canonical/ceph:latest
Expand All @@ -150,7 +103,7 @@ jobs:
- name: Deploy Cephadm over LXD Container
run: |
reg_addr=$(./test/scripts/cephadm_helper.sh get_ip)
sudo python test/deploy.py --osd-num 0 --container 1 --ceph-version reef image "$reg_addr:5000/canonical/ceph:latest"
sudo python test/deploy.py --osd-num 3 --ceph-version reef image "$reg_addr:5000/canonical/ceph:latest"
RookTest:
needs: build-rock
Expand Down
13 changes: 0 additions & 13 deletions confd/conf.d/ceph.conf.toml.in

This file was deleted.

31 changes: 0 additions & 31 deletions confd/templates/ceph.conf.tmpl

This file was deleted.

Binary file removed docker_scripts/Sree-0.2.tar.gz
Binary file not shown.
65 changes: 0 additions & 65 deletions docker_scripts/check_zombie_mons.py

This file was deleted.

Loading

0 comments on commit 93391b3

Please sign in to comment.