Skip to content

Commit

Permalink
[PRMP-639] - remove gocd pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
NogaNHS committed Aug 12, 2024
1 parent 758fccc commit 2d17218
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 743 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/base-gp-registrations-mi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
if: inputs.environment == 'prod' && inputs.is_deployment
run: |
aws ecr get-login-password --region ${{ vars.AWS_REGION }} | docker login --username AWS --password-stdin ${{ secrets.AWS_ECR_DEV_REPOSITORY }}
IMAGE_TAG=$(aws ecr describe-images --registy-id 123456789 --repository-name ${{ secrets.ECR_REPOSITORY_NAME }} --query 'sort_by(imageDetails,& imagePushedAt)[-1].imageTags[0]')
IMAGE_TAG=$(aws ecr describe-images --registy-id ${{ secrets.AWS_DEV_ACCOUNT_ID }} --repository-name ${{ secrets.ECR_REPOSITORY_NAME }} --query 'sort_by(imageDetails,& imagePushedAt)[-1].imageTags[0]')
source_repo=${{ secrets.AWS_ECR_DEV_REPOSITORY }}/${{ secrets.ECR_REPOSITORY_DEV_NAME }}:${IMAGE_TAG//\"}
destination_repo=${{ secrets.AWS_ECR_PROD_REPOSITORY}}/${{ secrets.ECR_REPOSITORY_NAME }}:${IMAGE_TAG//\"}
docker pull $source_repo
Expand Down
1 change: 0 additions & 1 deletion Dojofile

This file was deleted.

47 changes: 1 addition & 46 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,54 +1,9 @@
# prm-gp-registrations-mi-infra

## Setup

These instructions assume you are using:

- [aws-vault](https://github.com/99designs/aws-vault) to validate your AWS credentials.
- [dojo](https://github.com/kudulab/dojo) to provide an execution environment
- [colima](https://github.com/abiosoft/colima) to run the docker dojo images

## Applying terraform

Rolling out terraform against each environment is managed by the GoCD pipeline. If you'd like to test it locally, run the following commands:

1. Enter the container:

`aws-vault exec <profile-name> -- dojo`


2. Invoke terraform locally

```
./tasks validate <stack-name> <environment>
./tasks plan <stack-name> <environment>
```

The stack name denotes the specific stack you would like to validate.
The environment can be `dev` or `prod`.

To run the formatting, run `./tasks format <stack-name> <environment>`

## Troubleshooting
Error: `Too many command line arguments. Did you mean to use -chdir?`

If you are unable to validate/plan, make sure you doing it inside the dojo container by typing
```
dojo (then running command inside)
or
./tasks dojo-validate
```

Error: `Error: Error inspecting states in the "s3" backend:
S3 bucket does not exist.`

Try deleting the .terraform and the plans (dev.tfplan/prod.tfplan)
Rolling out terraform against each environment is managed by the GitHub Actions pipeline. The workflow files can be found in `.github/workflows`


Error: `docker: Cannot connect to the Docker daemon at unix:///Users/jnewman/.colima/docker.sock. Is the docker daemon running?.`

You need to install and start colima:
```
colima start
```
16 changes: 0 additions & 16 deletions environment.json

This file was deleted.

114 changes: 0 additions & 114 deletions gocd/base-networking.pipeline.gocd.yaml

This file was deleted.

114 changes: 0 additions & 114 deletions gocd/container-repositories.pipeline.gocd.yaml

This file was deleted.

Loading

0 comments on commit 2d17218

Please sign in to comment.