Skip to content

Commit

Permalink
Merge pull request #2003 from quadratichq/qa
Browse files Browse the repository at this point in the history
QA: Oct 30th
  • Loading branch information
ddimaria authored Nov 13, 2024
2 parents 8d4e7bb + 4af82b4 commit 51b25bd
Show file tree
Hide file tree
Showing 335 changed files with 20,841 additions and 5,808 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/production-publish-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Build and Publish Images to ECR

on:
push:
branches:
- self-hosting-setup #remove
- main

concurrency:
group: production-publish-images

jobs:
publish_images:
runs-on: ubuntu-latest-8-cores
strategy:
matrix:
service: [multiplayer, files, connection, client, api]
steps:
- uses: actions/checkout@v4

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1

- name: Login to Amazon ECR Public
id: login-ecr
uses: aws-actions/amazon-ecr-login@v2
with:
registry-type: public

- name: Define repository name
id: repo-name
run: |
echo "REPO_NAME=quadratic-${{ matrix.service }}" >> $GITHUB_OUTPUT
- name: Create Public ECR Repository if not exists
id: create-ecr
env:
REPO_NAME: ${{ steps.repo-name.outputs.REPO_NAME }}
run: |
aws ecr-public create-repository --repository-name $REPO_NAME || true
REPO_INFO=$(aws ecr-public describe-repositories --repository-names $REPO_NAME)
ECR_URL=$(echo $REPO_INFO | jq -r '.repositories[0].repositoryUri')
echo "ECR_URL=$ECR_URL" >> $GITHUB_OUTPUT
- name: Read VERSION file
id: version
run: echo "VERSION=$(cat VERSION)" >> $GITHUB_OUTPUT

- name: Build, Tag, and Push Image to Amazon ECR Public
env:
ECR_URL: ${{ steps.create-ecr.outputs.ECR_URL }}
IMAGE_TAG: ${{ steps.version.outputs.VERSION }}
run: |
docker build -t $ECR_URL:$IMAGE_TAG -t $ECR_URL:latest -f quadratic-${{ matrix.service }}/Dockerfile .
docker push $ECR_URL:$IMAGE_TAG
docker push $ECR_URL:latest
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ quadratic-connection/target/
quadratic-core/target/
quadratic-core/tmp.txt
quadratic-files/target/
quadratic-files/storage
quadratic-multiplayer/target/
quadratic-multiplayer/updateAlertVersion.json

Expand All @@ -64,6 +65,7 @@ docker/mysql/data
docker/postgres/data
docker/redis/data
docker/static/html
docker/file-storage
docker/postgres-connection/data
docker/mysql-connection/data
docker/snowflake-connection/data
Expand Down
10 changes: 3 additions & 7 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
"pyimport",
"rects",
"reqwest",
"scrollend",
"shadcn",
"Signin",
"smallpop",
Expand All @@ -55,13 +56,8 @@
"editor.codeActionsOnSave": {
"source.organizeImports": "explicit"
},
"rust-analyzer.linkedProjects": [
"./Cargo.toml",
"./quadratic-files/Cargo.toml",
"./quadratic-core/Cargo.toml",
"./quadratic-multiplayer/Cargo.toml",
"./quadratic-rust-client/Cargo.toml"
],
"rust-analyzer.runnables.extraEnv": { "CARGO_TARGET_DIR": "target/rust-analyzer" },
"rust-analyzer.check.extraArgs": ["--target-dir=target/rust-analyzer"],
"rust-analyzer.checkOnSave": true,
"rust-analyzer.cargo.unsetTest": true,
// "rust-analyzer.checkOnSave.command": "clippy",
Expand Down
Loading

0 comments on commit 51b25bd

Please sign in to comment.