MediaJel / mediajel-tracker

hosted mediajel tracker
4 stars 0 forks source link

Implement CI workflow for creating the S3 file for generating the carts #420

Closed pacholoamit closed 3 weeks ago

pacholoamit commented 2 months ago

Description

Steps:

  1. @jonmediajel , we need to create a script to read the mediajel-tracker/src/v1/imports/carts/index.ts file and parse out the environment names into the final format of the S3 generated carts.
jonmediajel commented 2 months ago

https://github.com/MediaJel/mediajel-tracker/pull/435 - all is done except for CI Workflow

jonmediajel commented 1 month ago

For re-QA = https://github.com/MediaJel/mediajel-tracker/pull/435

pacholoamit commented 1 month ago

Next step: Get in touch with Devops and add the command yarn tracker:generate-environments in the CI process in the final step of main after the aws cloudfront invalidate

  build-main:
    executor: the-executor
    steps:
      - checkout
      - run:
          name: Install project dependencies
          command: npm install
      - run:
          name: type checking
          command: npm run check
      - run:
          name: Cypress Install
          command: sudo apt-get update && sudo apt-get install libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 libxtst6 xauth xvfb
      - run:
          name: cypress tests
          command: npm run test
      - run:
          name: Build
          command: npm run deploy
      - aws-s3/sync:
          from: dist/
          to: "s3://mediajel-tracker-production"
          arguments: --cache-control "max-age=2628288"
      - aws-cloudfront/invalidate:
          distribution_id: E3NZWAOF5B6J2O
          paths: /*    
      - aws-cloudfront/invalidate:
          distribution_id: E3FT67SI37G1ZH
          paths: /*
      - aws-cloudfront/invalidate:
          distribution_id: EQGTP3X7S8LMI
          paths: /*
      - aws-cloudfront/invalidate:
          distribution_id: EFJHMMZDNURYT
          paths: /*
      - aws-cloudfront/invalidate:
          distribution_id: E3FT67SI37G1ZH
          paths: /*
      - aws-cloudfront/invalidate:
          distribution_id: EQGTP3X7S8LMI
          paths: /*
      - aws-cloudfront/invalidate:
          distribution_id: EFJHMMZDNURYT
          paths: /*
     // APPLY SCRIPT HERE
pacholoamit commented 1 month ago

Implement the tracker generation script in CI

pacholoamit commented 4 weeks ago

Update: Reach out to Joseph for status on implementing script in CI

jonmediajel commented 4 weeks ago

https://github.com/MediaJel/amplication-nestjs-microservices/commit/913903535ffdbc0718e69d835da2390f7a2b2ea2