Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

Version 1 Next »

Repository - https://github.com/project-sunbird/sunbird-devops

Cloud specific ansible role

  • We will need to create an OCI specific ansible role which can perform tasks such as upload / download / delete of files and folders etc.

  • Take a look at one of the existing cloud provider role such as AWS / GCP to understand what all operations are required as part of the role.

Ansible tasks related to storage buckets

Below is a sample block which uploads to AWS S3 bucket (https://github.com/project-sunbird/sunbird-devops/blob/release-5.1.0/ansible/artifacts-upload.yml#L30-L41 )

    - name: upload artifact to aws s3
      include_role:
        name: aws-cloud-storage
        tasks_from: upload.yml
      vars:
        local_file_or_folder_path: "{{ artifact_path }}"
        s3_bucket_name: "{{ cloud_storage_artifacts_bucketname }}"
        s3_path: "{{ artifact }}"
        aws_default_region: "{{ cloud_public_storage_region }}"
        aws_access_key_id: "{{ cloud_artifact_storage_accountname }}"
        aws_secret_access_key: "{{ cloud_artifact_storage_secret }}"
      when: cloud_service_provider == "aws"
  • In order to support OCI, we will need to add a similar block which can invoke the OCI specific roles and upload to OCI storage buckets

  • Below is the list of files that need to be modified to include the OCI storage role

 
  • No labels