pipelines:
  branches:
    master:
    - step:
        # runs-on:
        #   - self.hosted
        #   - linux
        #   - 8x
        size: 2x
        services:
          - docker
        caches:
          - docker
        script: # Modify the commands below to build your repository.
          - docker login --username $DOCKER_USERNAME --password $DOCKER_PASSWORD
          - docker build -f Dockerfile  -t 71dev/ru-manage-testing-web:dev .
          - docker push 71dev/ru-manage-testing-web:dev
    - step:
        # runs-on:
        #   - self.hosted
        #   - linux
        #   - 8x
        name: deploy to kubernates
        image: atlassian/pipelines-kubectl
        script:
          - echo $KUBE_CONFIG_DELL | base64 -d > kubeconfig
          - kubectl --insecure-skip-tls-verify  --kubeconfig=kubeconfig  rollout restart deployment/ru-manage-testing-deployment -n ru
definitions:
  services:
    docker:
      memory: 6144
