Skip to content

Commit

Permalink
NR-164383: add previous version
Browse files Browse the repository at this point in the history
  • Loading branch information
rogercoll committed Feb 8, 2024
1 parent 24d9ed3 commit 993cce2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/component_canaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,14 @@ jobs:
GIT_BRANCH=${GIT_BRANCH#refs/tags/}
echo "GIT_BRANCH=$GIT_BRANCH" >> $GITHUB_ENV
- name: Add to env current and previous versions
run: .github/workflows/scripts/set_version.sh ${{ inputs.TAG }}

- name: Provision canaries
uses: newrelic/fargate-runner-action@main
with:
aws_region: us-east-2
container_make_target: "macos-canaries PLATFORM=${{ inputs.PLATFORM }} ANSIBLE_FORKS=${{ env.ANSIBLE_FORKS }} VERSION=${{ inputs.TAG }} CROWDSTRIKE_CLIENT_ID=${{ secrets.CROWDSTRIKE_CLIENT_ID }} CROWDSTRIKE_CLIENT_SECRET=${{ secrets.CROWDSTRIKE_CLIENT_SECRET }} CROWDSTRIKE_CUSTOMER_ID=${{ secrets.CROWDSTRIKE_CUSTOMER_ID }}"
container_make_target: "macos-canaries PLATFORM=${{ inputs.PLATFORM }} ANSIBLE_FORKS=${{ env.ANSIBLE_FORKS }} PREVIOUS_VERSION=${{ env.PREVIOUS_NR_VERSION }} VERSION=${{ inputs.TAG }} CROWDSTRIKE_CLIENT_ID=${{ secrets.CROWDSTRIKE_CLIENT_ID }} CROWDSTRIKE_CLIENT_SECRET=${{ secrets.CROWDSTRIKE_CLIENT_SECRET }} CROWDSTRIKE_CUSTOMER_ID=${{ secrets.CROWDSTRIKE_CUSTOMER_ID }}"
ecs_cluster_name: caos_infra_agent
task_definition_name: infra-agent
cloud_watch_logs_group_name: /ecs/test-prerelease-infra-agent
Expand Down
3 changes: 3 additions & 0 deletions test/canaries/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ endif
ifndef CROWDSTRIKE_CUSTOMER_ID
$(error CROWDSTRIKE_CUSTOMER_ID \(Crowdstrike customer ID\) variable must be provided)
exit 1
endif
ifndef PREVIOUS_VERSION
$(error PREVIOUS_VERSION is not set)
endif
@ansible-playbook -f $(ANSIBLE_FORKS) -i $(ANSIBLE_INVENTORY) "$(ANSIBLE_FOLDER)/inventory_macos_canaries.yml" -e "macstadium_user=$(MACSTADIUM_USER) macstadium_pass=$(MACSTADIUM_PASS) macstadium_sudo_pass=$(MACSTADIUM_SUDO_PASS) output_inventory_macos=$(CURDIR)/inventory.macos.ec2 platform=macos"
sed -i.bak "s/canary:current/canary-macos:v$(VERSION)/g" $(CURDIR)/inventory.macos.ec2
Expand Down

0 comments on commit 993cce2

Please sign in to comment.