Skip to content

Commit

Permalink
Deployment updates
Browse files Browse the repository at this point in the history
  • Loading branch information
philip-linaro committed Sep 26, 2024
1 parent 4d7374b commit efb342a
Show file tree
Hide file tree
Showing 6 changed files with 88 additions and 9 deletions.
66 changes: 66 additions & 0 deletions .github/workflows/push_main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: PushToMainAction

on:
push:
branches: ["main"]
workflow_dispatch:

# Cancel in-progress jobs or runs for the current workflow
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
NODE_VERSION: "20.x"

permissions:
contents: read

jobs:
build:
runs-on: self-hosted
steps:
- name: Fetch git repository
uses: actions/[email protected]
with:
fetch-depth: "0"

- uses: actions/cache/restore@v3
id: cache
with:
path: |
cache
.sst
key: cache-main

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
cache: "npm"

- name: Build and deploy
run: |
# Set up the environment variables
export NODE_OPTIONS=--experimental-wasm-modules
export IS_PUBLIC=true
export CUSTOM_DOMAIN=ecosystemdashboard.linaro.org
export CLOUDINARY_CLOUD_NAME=${{ secrets.CLOUDINARY_CLOUD_NAME }}
export CLOUDINARY_API_KEY=${{ secrets.CLOUDINARY_API_KEY }}
export CLOUDINARY_API_SECRET=${{ secrets.CLOUDINARY_API_SECRET }}
# Set up yarn
yarn install
pipenv install
$(pipenv run python ./get_aws_creds.py -i ${{ secrets.VAULT_ROLE_ID }} -s ${{ secrets.VAULT_SECRET_ID }} -r ${{ secrets.VAULT_ROLE }} 2>&1 | tee /dev/stderr)
# Build & deploy
if [ -d "dist" ]; then
rm -rf dist
fi
yarn sst deploy --stage prod
- uses: actions/cache/save@v4
with:
path: |
cache
.sst
key: cache-main
13 changes: 13 additions & 0 deletions Pipfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
requests = "*"
yamllint = "*"

[dev-packages]

[requires]
python_version = "3"
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Linaro Arm Ecosystem Dashboard Astro Site

This is the git repository for the [https://ecosystemlandscape.linaro.org](https://ecosystemdashboard.linaro.org/) static Astro website.
This is the git repository for the [https://ecosystemdashboard.linaro.org](https://ecosystemdashboard.linaro.org/) static Astro website.

Hosted in this repo are the markdown content files associated with the website. Feel free to [submit a PR](https://github.com/Linaro/ecosystemlandscape-astro/pulls) / [Issue](https://github.com/Linaro/ecosystemlandscape-astro/issues/new) if there is anything you would like to change.
Hosted in this repo are the markdown content files associated with the website. Feel free to [submit a PR](https://github.com/Linaro/ecosystemdashboard-astro/pulls) / [Issue](https://github.com/Linaro/ecosystemdashboard-astro/issues/new) if there is anything you would like to change.

---

Expand Down Expand Up @@ -41,7 +41,7 @@ Directory "src/content/projects/" contains all the sub-page info using yaml, so

\*\* offer a “not available” option so we can flag it.

[1]: https://github.com/Linaro/ecosystemlandscape/blob/main/_posts/2021-08-31-ApacheHadoop.md?plain=1#L32
[1]: https://github.com/Linaro/ecosystemdashboard/blob/main/_posts/2021-08-31-ApacheHadoop.md?plain=1#L32

## Dependencies

Expand Down
6 changes: 3 additions & 3 deletions cdk.context.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"hosted-zone:account=691071635361:domainName=neweco.linaro.org:region=us-east-1": {
"Id": "/hostedzone/Z040981729XZPK2E08JLZ",
"Name": "neweco.linaro.org."
"hosted-zone:account=691071635361:domainName=ecosystemdashboard.linaro.org:region=us-east-1": {
"Id": "/hostedzone/Z04357211XJJV09HUGP1C",
"Name": "ecosystemdashboard.linaro.org."
}
}
2 changes: 1 addition & 1 deletion src/content/pages/homepage.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ flow:
text_content: Click the logo for a project to check Arm support details
style: text-center text-2xl mt-16
- component: text
text_content: Want to submit a project? <br>[Click here](https://github.com/Linaro/ecosystemlandscape-astro#project-details-structure) for guidelines and instructions first
text_content: Want to submit a project? <br>[Click here](https://github.com/Linaro/ecosystemdashboard-astro#project-details-structure) for guidelines and instructions first
style: text-center text-2xl mb-0 mt-8
- row: container_row
sections:
Expand Down
4 changes: 2 additions & 2 deletions sst.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ import { AstroSite } from "sst/constructs";
export default {
config(_input) {
return {
name: "ecosystemlandscape-website",
name: "ecosystemdashboard-website",
region: "us-east-1",
};
},
stacks(app) {
app.stack(function Site({ stack }) {
const site = new AstroSite(stack, "EcosystemLandscapeStaticSite", {
const site = new AstroSite(stack, "EcosystemDashboardStaticSite", {
customDomain: {
// domainAlias: process.env.CUSTOM_DOMAIN!.replace("www.", ""),
domainName: process.env.CUSTOM_DOMAIN!,
Expand Down

0 comments on commit efb342a

Please sign in to comment.