Skip to content

Commit

Permalink
feat: add ci support for ceph_rados (#4191)
Browse files Browse the repository at this point in the history
* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* feat: add ci support for ceph_rados

* Add ceph rados

Signed-off-by: Xuanwo <github@xuanwo.io>

* Make sure minio is the default CI

Signed-off-by: Xuanwo <github@xuanwo.io>

* Create bucket

Signed-off-by: Xuanwo <github@xuanwo.io>

* Oh, ceph

Signed-off-by: Xuanwo <github@xuanwo.io>

---------

Signed-off-by: Xuanwo <github@xuanwo.io>
Co-authored-by: Xuanwo <github@xuanwo.io>
  • Loading branch information
zhenglin-charlie-li and Xuanwo authored Feb 26, 2024
1 parent 6df728a commit 6deda27
Show file tree
Hide file tree
Showing 3 changed files with 92 additions and 0 deletions.
File renamed without changes.
44 changes: 44 additions & 0 deletions .github/services/s3/ceph_rados_s3/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

name: ceph_rados_s3
description: 'Behavior test for CEPH OBJECT GATEWAY S3'

runs:
using: "composite"
steps:
- name: Setup Ceph Rados Server
shell: bash
working-directory: fixtures/s3
run: docker compose -f docker-compose-ceph-rados.yml up -d --wait

# ceph/demo has support for CEPH_DEMO_BUCKET, but it doesn't work as expected.
- name: Create bucket
shell: bash
working-directory: fixtures/s3
run: docker exec ceph-demo s3cmd mb s3://demo

- name: Setup
shell: bash
run: |
cat << EOF >> $GITHUB_ENV
OPENDAL_S3_BUCKET=demo
OPENDAL_S3_ENDPOINT=http://127.0.0.1:8080
OPENDAL_S3_ACCESS_KEY_ID=demo
OPENDAL_S3_SECRET_ACCESS_KEY=demo
OPENDAL_S3_REGION=us-east-1
EOF
48 changes: 48 additions & 0 deletions fixtures/s3/docker-compose-ceph-rados.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

version: "3.8"

services:
ceph-demo:
image: quay.io/ceph/demo
container_name: ceph-demo
environment:
- MON_IP=127.0.0.1
- CEPH_PUBLIC_NETWORK=0.0.0.0/0
- DEMO_DAEMONS=osd,mds,rgw
- CEPH_DEMO_UID=demo
- CEPH_DEMO_ACCESS_KEY=demo
- CEPH_DEMO_SECRET_KEY=demo
# ceph/demo failed to create bucket for us, let's create it by hand.
# - CEPH_DEMO_BUCKET=demo
ports:
- "8080:8080" # Dashboard
- "5000:5000" # REST API
- "6789:6789" # Ceph monitor
volumes:
- ceph-vol:/var/lib/ceph/
network_mode: "host"
# Give ceph enough time to start up, it's really, really slow.
# We will wait up to 10 minutes.
healthcheck:
test: [ "CMD", "s3cmd", "ls" ]
interval: 6s
retries: 100

volumes:
ceph-vol:

0 comments on commit 6deda27

Please sign in to comment.