name: 'Deploy docker image cuttlefish-orchestration'
inputs:
  arch:
    required: true
  image-version:
    required: true
runs:
  using: "composite"
  steps:
  - name: Deploy docker image into Artifact Registry
    run: |
      TAG=${INPUTS_IMAGE_VERSION}-${INPUTS_ARCH}
      REMOTE_IMAGE_TAG=us-docker.pkg.dev/android-cuttlefish-artifacts/cuttlefish-orchestration/cuttlefish-orchestration:${TAG}

      docker tag cuttlefish-orchestration ${REMOTE_IMAGE_TAG}
      docker push ${REMOTE_IMAGE_TAG}
    shell: bash
    env:
      INPUTS_ARCH: ${{ inputs.arch }}
      INPUTS_IMAGE_VERSION: ${{ inputs.image-version }}
