mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 18:43:34 +00:00
Fresh dep ensure
This commit is contained in:
3
vendor/k8s.io/kubernetes/test/images/volume/iscsi/BASEIMAGE
generated
vendored
Normal file
3
vendor/k8s.io/kubernetes/test/images/volume/iscsi/BASEIMAGE
generated
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
amd64=fedora:28
|
||||
arm64=arm64v8/fedora:28
|
||||
ppc64le=ppc64le/fedora:28
|
35
vendor/k8s.io/kubernetes/test/images/volume/iscsi/Dockerfile
generated
vendored
Normal file
35
vendor/k8s.io/kubernetes/test/images/volume/iscsi/Dockerfile
generated
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
# Copyright 2016 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed 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.
|
||||
|
||||
FROM BASEIMAGE
|
||||
|
||||
CROSS_BUILD_COPY qemu-QEMUARCH-static /usr/bin/
|
||||
|
||||
RUN yum install -y iscsi-initiator-utils targetcli net-tools strace procps-ng psmisc && yum clean all
|
||||
ADD run_iscsid.sh /usr/local/bin/
|
||||
ADD initiatorname.iscsi /etc/iscsi/
|
||||
ADD block.tar.gz /
|
||||
|
||||
# This JSON file was generated by targetcli with these commands:
|
||||
# /backstores/fileio create block /block
|
||||
# /iscsi create
|
||||
# # Enable demo mode (no authentication!):
|
||||
# /iscsi/iqn.2003-01.org.linux-iscsi.f21.x8664:sn.4b0aae584f7c/tpg1 set attribute authentication=0 demo_mode_write_protect=0 generate_node_acls=1 cache_dynamic_acls=1
|
||||
# /iscsi/iqn.2003-01.org.linux-iscsi.f21.x8664:sn.4b0aae584f7c/tpg1/luns create /backstores/fileio/block
|
||||
# saveconfig
|
||||
ADD saveconfig.json /etc/target/
|
||||
|
||||
EXPOSE 3260/tcp
|
||||
|
||||
ENTRYPOINT ["/usr/local/bin/run_iscsid.sh"]
|
14
vendor/k8s.io/kubernetes/test/images/volume/iscsi/README.md
generated
vendored
Normal file
14
vendor/k8s.io/kubernetes/test/images/volume/iscsi/README.md
generated
vendored
Normal file
@ -0,0 +1,14 @@
|
||||
# iSCSI target container for testing.
|
||||
|
||||
Inspired by https://github.com/rvykydal/dockerfile-iscsid
|
||||
|
||||
* The container needs /lib/modules from the host to insert appropriate
|
||||
kernel modules for iscsi. This assumes that these modules are installed
|
||||
on the host!
|
||||
|
||||
* The container needs to run with docker --privileged
|
||||
|
||||
block.tar.gz is a small ext2 filesystem created by `create_block.sh` (run as root!)
|
||||
|
||||
|
||||
[]()
|
1
vendor/k8s.io/kubernetes/test/images/volume/iscsi/VERSION
generated
vendored
Normal file
1
vendor/k8s.io/kubernetes/test/images/volume/iscsi/VERSION
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
1.0
|
BIN
vendor/k8s.io/kubernetes/test/images/volume/iscsi/block.tar.gz
generated
vendored
Normal file
BIN
vendor/k8s.io/kubernetes/test/images/volume/iscsi/block.tar.gz
generated
vendored
Normal file
Binary file not shown.
47
vendor/k8s.io/kubernetes/test/images/volume/iscsi/create_block.sh
generated
vendored
Executable file
47
vendor/k8s.io/kubernetes/test/images/volume/iscsi/create_block.sh
generated
vendored
Executable file
@ -0,0 +1,47 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright 2015 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed 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.
|
||||
|
||||
# Exit on the first error.
|
||||
set -e
|
||||
|
||||
MNTDIR=`mktemp -d`
|
||||
|
||||
cleanup()
|
||||
{
|
||||
# Make sure we return the right exit code
|
||||
RET=$?
|
||||
# Silently remove everything and ignore errors
|
||||
set +e
|
||||
/bin/umount $MNTDIR 2>/dev/null
|
||||
/bin/rmdir $MNTDIR 2>/dev/null
|
||||
/bin/rm block 2>/dev/null
|
||||
exit $RET
|
||||
}
|
||||
|
||||
trap cleanup TERM EXIT
|
||||
|
||||
# Create 120MB device with ext2
|
||||
# (volume_io tests need at least 100MB)
|
||||
dd if=/dev/zero of=block seek=120 count=1 bs=1M
|
||||
mkfs.ext2 block
|
||||
|
||||
# Add index.html to it
|
||||
mount -o loop block $MNTDIR
|
||||
echo "Hello from iSCSI" > $MNTDIR/index.html
|
||||
umount $MNTDIR
|
||||
|
||||
rm block.tar.gz 2>/dev/null || :
|
||||
tar cfz block.tar.gz block
|
1
vendor/k8s.io/kubernetes/test/images/volume/iscsi/initiatorname.iscsi
generated
vendored
Normal file
1
vendor/k8s.io/kubernetes/test/images/volume/iscsi/initiatorname.iscsi
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
InitiatorName=iqn.1994-05.com.redhat:eb59fbe2c4c5
|
51
vendor/k8s.io/kubernetes/test/images/volume/iscsi/run_iscsid.sh
generated
vendored
Executable file
51
vendor/k8s.io/kubernetes/test/images/volume/iscsi/run_iscsid.sh
generated
vendored
Executable file
@ -0,0 +1,51 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright 2015 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed 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.
|
||||
|
||||
function start()
|
||||
{
|
||||
# targetcli need dbus
|
||||
mkdir /run/dbus
|
||||
dbus-daemon --system
|
||||
|
||||
# clear any previous configuration
|
||||
targetcli clearconfig confirm=True
|
||||
|
||||
# restore configuration from saveconfig.json
|
||||
targetcli restoreconfig
|
||||
|
||||
# maximum log level
|
||||
iscsid -f -d 8
|
||||
|
||||
echo "iscsid started"
|
||||
}
|
||||
|
||||
function stop()
|
||||
{
|
||||
echo "Stopping iscsid"
|
||||
killall iscsid
|
||||
targetcli clearconfig confirm=True
|
||||
|
||||
echo "iscsid stopped"
|
||||
exit 0
|
||||
}
|
||||
|
||||
|
||||
trap stop TERM
|
||||
start
|
||||
|
||||
while true; do
|
||||
sleep 5
|
||||
done
|
102
vendor/k8s.io/kubernetes/test/images/volume/iscsi/saveconfig.json
generated
vendored
Normal file
102
vendor/k8s.io/kubernetes/test/images/volume/iscsi/saveconfig.json
generated
vendored
Normal file
@ -0,0 +1,102 @@
|
||||
{
|
||||
"fabric_modules": [],
|
||||
"storage_objects": [
|
||||
{
|
||||
"attributes": {
|
||||
"block_size": 512,
|
||||
"emulate_3pc": 1,
|
||||
"emulate_caw": 1,
|
||||
"emulate_dpo": 0,
|
||||
"emulate_fua_read": 0,
|
||||
"emulate_fua_write": 1,
|
||||
"emulate_model_alias": 1,
|
||||
"emulate_rest_reord": 0,
|
||||
"emulate_tas": 1,
|
||||
"emulate_tpu": 0,
|
||||
"emulate_tpws": 0,
|
||||
"emulate_ua_intlck_ctrl": 0,
|
||||
"emulate_write_cache": 1,
|
||||
"enforce_pr_isids": 1,
|
||||
"force_pr_aptpl": 0,
|
||||
"is_nonrot": 0,
|
||||
"max_unmap_block_desc_count": 1,
|
||||
"max_unmap_lba_count": 8192,
|
||||
"max_write_same_len": 4096,
|
||||
"optimal_sectors": 16384,
|
||||
"pi_prot_format": 0,
|
||||
"pi_prot_type": 0,
|
||||
"queue_depth": 128,
|
||||
"unmap_granularity": 1,
|
||||
"unmap_granularity_alignment": 0
|
||||
},
|
||||
"dev": "block",
|
||||
"name": "block",
|
||||
"plugin": "fileio",
|
||||
"size": 126877696,
|
||||
"write_back": true,
|
||||
"wwn": "521c57aa-9d9b-4e5d-ab1a-527487f92a33"
|
||||
}
|
||||
],
|
||||
"targets": [
|
||||
{
|
||||
"fabric": "iscsi",
|
||||
"tpgs": [
|
||||
{
|
||||
"attributes": {
|
||||
"authentication": 0,
|
||||
"cache_dynamic_acls": 1,
|
||||
"default_cmdsn_depth": 64,
|
||||
"default_erl": 0,
|
||||
"demo_mode_discovery": 1,
|
||||
"demo_mode_write_protect": 0,
|
||||
"generate_node_acls": 1,
|
||||
"login_timeout": 15,
|
||||
"netif_timeout": 2,
|
||||
"prod_mode_write_protect": 0,
|
||||
"t10_pi": 0
|
||||
},
|
||||
"enable": true,
|
||||
"luns": [
|
||||
{
|
||||
"index": 0,
|
||||
"storage_object": "/backstores/fileio/block"
|
||||
}
|
||||
],
|
||||
"node_acls": [],
|
||||
"parameters": {
|
||||
"AuthMethod": "CHAP,None",
|
||||
"DataDigest": "CRC32C,None",
|
||||
"DataPDUInOrder": "Yes",
|
||||
"DataSequenceInOrder": "Yes",
|
||||
"DefaultTime2Retain": "20",
|
||||
"DefaultTime2Wait": "2",
|
||||
"ErrorRecoveryLevel": "0",
|
||||
"FirstBurstLength": "65536",
|
||||
"HeaderDigest": "CRC32C,None",
|
||||
"IFMarkInt": "2048~65535",
|
||||
"IFMarker": "No",
|
||||
"ImmediateData": "Yes",
|
||||
"InitialR2T": "Yes",
|
||||
"MaxBurstLength": "262144",
|
||||
"MaxConnections": "1",
|
||||
"MaxOutstandingR2T": "1",
|
||||
"MaxRecvDataSegmentLength": "8192",
|
||||
"MaxXmitDataSegmentLength": "262144",
|
||||
"OFMarkInt": "2048~65535",
|
||||
"OFMarker": "No",
|
||||
"TargetAlias": "LIO Target"
|
||||
},
|
||||
"portals": [
|
||||
{
|
||||
"ip_address": "0.0.0.0",
|
||||
"iser": false,
|
||||
"port": 3260
|
||||
}
|
||||
],
|
||||
"tag": 1
|
||||
}
|
||||
],
|
||||
"wwn": "iqn.2003-01.org.linux-iscsi.f21.x8664:sn.4b0aae584f7c"
|
||||
}
|
||||
]
|
||||
}
|
Reference in New Issue
Block a user