service-status-app

Service
Log | Files | Refs | README

playbook.yml (579B)


      1 ---
      2 - hosts: 127.0.0.1
      3   connection: local
      4   tasks:
      5     - name: Build Docker image
      6       docker_image:
      7         name: service-status-app
      8         state: present
      9         source: build
     10         force_source: true
     11         build:
     12           path: "{{ playbook_dir }}/python_app"
     13           rm: true
     14         tag: latest
     15       register: build_result
     16     - name: Run Docker container
     17       docker_container:
     18         name: service-status-app
     19         image: service-status-app:latest
     20         state: started
     21         recreate: "{{ build_result.changed }}"
     22         ports:
     23           - "8000:8000"