-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Sergio Castaño Arteaga <tegioz@icloud.com>
- Loading branch information
Showing
1 changed file
with
55 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
name: CNCF | ||
on: | ||
schedule: | ||
- cron: "0 10 * * *" | ||
|
||
jobs: | ||
build-and-deploy-landscape: | ||
runs-on: ubuntu-latest | ||
container: | ||
image: public.ecr.aws/g6m3a0y9/landscape2 | ||
options: --user root | ||
steps: | ||
- name: Checkout this repository | ||
uses: actions/checkout@v3 | ||
|
||
- name: Checkout cncf/landscape repository | ||
uses: actions/checkout@v3 | ||
with: | ||
repository: "cncf/landscape" | ||
path: "./landscape" | ||
sparse-checkout: | | ||
hosted_logos | ||
- name: Install tar in container (needed for the cache) | ||
run: apk add --update --no-progress tar | ||
|
||
- name: Setup cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: /tmp/landscape-cache | ||
key: landscape-cache-cncf-${ github.sha }} | ||
restore-keys: | | ||
landscape-cache-cncf- | ||
- name: Build landscape | ||
env: | ||
GITHUB_TOKENS: ${{ secrets.GH_TOKENS }} | ||
CRUNCHBASE_API_KEY: ${{ secrets.CRUNCHBASE_API_KEY }} | ||
run: | | ||
landscape2 build \ | ||
--settings-file ./cncf/settings.yml \ | ||
--data-file ./landscape/landscape.yml \ | ||
--logos-path ./landscape/hosted_logos \ | ||
--cache-dir /tmp/landscape-cache \ | ||
--output-dir /tmp/landscape | ||
- name: Deploy landscape | ||
env: | ||
AWS_REGION: "us-east-2" | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
run: | | ||
landscape2 deploy s3 \ | ||
--bucket landscape2-prototype-demo \ | ||
--landscape-dir /tmp/landscape |