Skip to content

Commit

Permalink
Replace Buildkite with Github Action
Browse files Browse the repository at this point in the history
Problem: we would like to decommission Buildkite usage in all
our repos

Solution: replace Buildkite with Github Action
  • Loading branch information
karandit committed Sep 28, 2023
1 parent a39c2b1 commit 15801a9
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 19 deletions.
19 changes: 0 additions & 19 deletions .buildkite/pipeline.yml

This file was deleted.

20 changes: 20 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: deploy
on: push
env:
NIX_PATH: "nixpkgs=channel:nixos-unstable"
CDN_DISTRIBUTION_ID: "E37J93462NMI5V"
CDN_BUCKET: "s3://ghc.dev-prod"

jobs:
deploy_to_AWS:
runs-on: [self-hosted, nix]
steps:
- uses: actions/checkout@v4
- name: build
run: nix build
- name: deploy
# if: github.ref_name == 'master'
run: |
nix-shell -p awscli --run "aws s3 cp result/out $CDN_BUCKET/ --recursive"
echo +++ Invalidating cache
nix-shell -p awscli --run "aws cloudfront create-invalidation --distribution-id $CDN_DISTRIBUTION_ID --paths '/*'"
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,6 @@ tags

# Output
out

# Temporary files generated by nix
result

0 comments on commit 15801a9

Please sign in to comment.