You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

start.sh 807 B

1 year ago
1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #!/bin/bash
  2. #!/bin/bash
  3. # 获取当前路径
  4. current_path=$(pwd)
  5. # 拉起configmap
  6. cd $current_path/config
  7. config_files=$(ls *.json 2>/dev/null)
  8. if [ -z "$config_files" ]; then
  9. echo "当前路径下没有.config.json文件。"
  10. exit 1
  11. fi
  12. for file in $config_files; do
  13. if [[ -f "$file" ]]; then
  14. name=$(echo "$file" | cut -d '.' -f1)
  15. service_name=$(echo "$name" | cut -d '-' -f1)
  16. kubectl create cm $name-config --from-file=$service_name.config.json=./$file
  17. fi
  18. done
  19. # 拉起pod
  20. pv_yaml_files=$(ls rclone_pv_*.yaml 2>/dev/null)
  21. for pv_yaml_file in $pv_yaml_files; do
  22. echo "Applying $pv_yaml_file ..."
  23. kubectl apply -f $pv_yaml_file
  24. done
  25. cd $current_path
  26. yaml_files=$(ls *.yaml 2>/dev/null)
  27. for yaml_file in $yaml_files; do
  28. echo "Applying $yaml_file ..."
  29. kubectl apply -f $yaml_file
  30. done

本项目旨在将云际存储公共基础设施化,使个人及企业可低门槛使用高效的云际存储服务(安装开箱即用云际存储客户端即可,无需关注其他组件的部署),同时支持用户灵活便捷定制云际存储的功能细节。