Skip to content

Commit

Permalink
feat: registration_rust (#170)
Browse files Browse the repository at this point in the history
  • Loading branch information
aldy505 authored Apr 12, 2024
1 parent c99235c commit 4e320a3
Show file tree
Hide file tree
Showing 8 changed files with 3,064 additions and 0 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/systems-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,24 @@ jobs:
- name: Build
run: dotnet build "Registration.csproj" --no-restore -c Release

registration_rust:
name: Registration Rust
runs-on: ubuntu-latest
container: rust:1.77
timeout-minutes: 30
defaults:
run:
working-directory: ./registration_rust
services:
db:
image: redis:7-bookworm
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Build
run: cargo build --release

build-database:
name: Build Database
runs-on: ubuntu-latest
Expand Down Expand Up @@ -432,6 +450,48 @@ jobs:
environment: production
ignore_empty: true

build-registration_rust:
name: Build Registration Rust
runs-on: ubuntu-latest
timeout-minutes: 30
needs:
- registration_rust
permissions:
contents: read
packages: write
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-registration_rust
flavor: |
latest=false
tags: |
type=edge
type=sha
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: "{{defaultContext}}:registration_rust"
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

dogfood:
name: Dogfood Integration Tests
runs-on: ubuntu-latest
Expand Down
56 changes: 56 additions & 0 deletions .github/workflows/systems-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,21 @@ jobs:
- name: Build
run: dotnet build "Registration.csproj" --no-restore -c Release

registration_rust:
name: Registration Rust
runs-on: ubuntu-latest
container: rust:1.77
timeout-minutes: 30
defaults:
run:
working-directory: ./registration_rust
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Build
run: cargo build --release

build-auth:
name: Build Auth
runs-on: ubuntu-latest
Expand Down Expand Up @@ -353,6 +368,47 @@ jobs:
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

build-registration_rust:
name: Build Registration Rust
runs-on: ubuntu-latest
timeout-minutes: 30
needs:
- registration_rust
permissions:
contents: read
packages: write
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-registration_rust
flavor: |
latest=false
tags: |
type=ref,event=pr
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: "{{defaultContext}}:registration_rust"
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

dogfood:
name: Dogfood Integration Tests
runs-on: ubuntu-latest
Expand Down
15 changes: 15 additions & 0 deletions registration_rust/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
### Rust template
# Generated by Cargo
# will have compiled files and executables
debug/
target/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
# Cargo.lock

# These are backup files generated by rustfmt
**/*.rs.bk

# MSVC Windows builds of rustc generate these, which store debugging information
*.pdb
15 changes: 15 additions & 0 deletions registration_rust/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
### Rust template
# Generated by Cargo
# will have compiled files and executables
debug/
target/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
# Cargo.lock

# These are backup files generated by rustfmt
**/*.rs.bk

# MSVC Windows builds of rustc generate these, which store debugging information
*.pdb
Loading

0 comments on commit 4e320a3

Please sign in to comment.