-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2165 from smeup/dev-to-mas
10.0.1
- Loading branch information
Showing
148 changed files
with
5,614 additions
and
660 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 |
---|---|---|
@@ -1,149 +1,149 @@ | ||
name: continuum | ||
|
||
on: | ||
push: | ||
branches: | ||
- develop | ||
push: | ||
branches: | ||
- develop | ||
|
||
env: | ||
VERSION: 10.0.0-SNAPSHOT | ||
AWS_REGION: eu-south-1 | ||
VERSION: 11.0.0-SNAPSHOT | ||
AWS_REGION: eu-south-1 | ||
|
||
jobs: | ||
ketchup-release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "18.16.0" | ||
cache: "yarn" | ||
|
||
- name: Install dependencies | ||
run: yarn install --immutable | ||
|
||
- name: Run Ketchup build | ||
run: npm run k:build | ||
|
||
- name: Run Ketchup Showcase build | ||
run: npm run ksc:build | ||
|
||
- name: Zip artifacts | ||
run: | | ||
cd packages/ketchup/dist | ||
zip -qr /tmp/ketchup.zip * | ||
zip -qr /tmp/ketchup-components.zip ketchup/* | ||
- name: Setup AWS | ||
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: ${{ env.AWS_REGION }} | ||
|
||
- name: Upload artifacts to AWS S3 | ||
run: | | ||
aws s3 cp /tmp/ketchup.zip s3://smeup-ketchup/npm-pub/ketchup-stencil/${{ env.VERSION }}/zip/ketchup.zip | ||
aws s3 cp /tmp/ketchup-components.zip s3://smeup-ketchup/npm-pub/ketchup-stencil/${{ env.VERSION }}/zip/ketchup-components.zip | ||
# Prepare GitHub Pages Showcase deployment | ||
- name: Setup GitHub Pages | ||
uses: actions/configure-pages@v5 | ||
- name: Upload GitHub Pages artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: "./packages/ketchup-showcase/dist" | ||
|
||
# Showcase Deployment Job | ||
showcase-release: | ||
needs: ketchup-release | ||
runs-on: ubuntu-latest | ||
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment | ||
permissions: | ||
pages: write # to deploy to Pages | ||
id-token: write # to verify the deployment originates from an appropriate source | ||
|
||
# Deploy to the github-pages environment | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 | ||
|
||
build: | ||
runs-on: ubuntu-latest | ||
needs: ketchup-release | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: '18.x' | ||
registry-url: 'https://registry.npmjs.org' | ||
|
||
- name: Install dependencies | ||
run: yarn install --no-immutable | ||
|
||
- name: Update Ketchup Version with Timestamp | ||
run: | | ||
cd packages/ketchup | ||
VERSION=$(node -p "require('./package.json').version") | ||
TIMESTAMP=$(date +%Y%m%d%H%M%S) | ||
NEW_VERSION="${VERSION}-${TIMESTAMP}" | ||
echo "New version: $NEW_VERSION" | ||
sed -i "s/\"version\": \"$VERSION\"/\"version\": \"$NEW_VERSION\"/" ./package.json | ||
- name: Update Ketchup React Version with Timestamp | ||
run: | | ||
cd packages/ketchup-react | ||
VERSION=$(node -p "require('./package.json').version") | ||
TIMESTAMP=$(date +%Y%m%d%H%M%S) | ||
NEW_VERSION="${VERSION}-${TIMESTAMP}" | ||
echo "New version: $NEW_VERSION" | ||
sed -i "s/\"version\": \"$VERSION\"/\"version\": \"$NEW_VERSION\"/" ./package.json | ||
- name: Run Ketchup build | ||
run: npm run k:build | ||
|
||
- name: Publish Ketchup | ||
run: | | ||
cd packages/ketchup | ||
npm publish | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
|
||
- name: Publish Ketchup React | ||
run: | | ||
cd packages/ketchup-react | ||
npm publish | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
|
||
trigger-webup-continuum: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- run: | | ||
curl -L \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: Bearer ${{ secrets.ROBBY_SMEUP_PAT }}" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
https://api.github.com/repos/smeup/webup-project/actions/workflows/continuum.yaml/dispatches \ | ||
-d '{"ref": "develop"}' | ||
trigger-webupjs-develop: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- run: | | ||
curl -L \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: Bearer ${{ secrets.ROBBY_SMEUP_PAT }}" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
https://api.github.com/repos/smeup/webup.js/actions/workflows/develop-release.yaml/dispatches \ | ||
-d '{"ref": "develop"}' | ||
ketchup-release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: '18.16.0' | ||
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
run: yarn install --immutable | ||
|
||
- name: Run Ketchup build | ||
run: npm run k:build | ||
|
||
- name: Run Ketchup Showcase build | ||
run: npm run ksc:build | ||
|
||
- name: Zip artifacts | ||
run: | | ||
cd packages/ketchup/dist | ||
zip -qr /tmp/ketchup.zip * | ||
zip -qr /tmp/ketchup-components.zip ketchup/* | ||
- name: Setup AWS | ||
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: ${{ env.AWS_REGION }} | ||
|
||
- name: Upload artifacts to AWS S3 | ||
run: | | ||
aws s3 cp /tmp/ketchup.zip s3://smeup-ketchup/npm-pub/ketchup-stencil/${{ env.VERSION }}/zip/ketchup.zip | ||
aws s3 cp /tmp/ketchup-components.zip s3://smeup-ketchup/npm-pub/ketchup-stencil/${{ env.VERSION }}/zip/ketchup-components.zip | ||
# Prepare GitHub Pages Showcase deployment | ||
- name: Setup GitHub Pages | ||
uses: actions/configure-pages@v5 | ||
- name: Upload GitHub Pages artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: './packages/ketchup-showcase/dist' | ||
|
||
# Showcase Deployment Job | ||
showcase-release: | ||
needs: ketchup-release | ||
runs-on: ubuntu-latest | ||
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment | ||
permissions: | ||
pages: write # to deploy to Pages | ||
id-token: write # to verify the deployment originates from an appropriate source | ||
|
||
# Deploy to the github-pages environment | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 | ||
|
||
build: | ||
runs-on: ubuntu-latest | ||
needs: ketchup-release | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: '18.x' | ||
registry-url: 'https://registry.npmjs.org' | ||
|
||
- name: Install dependencies | ||
run: yarn install --no-immutable | ||
|
||
- name: Update Ketchup Version with Timestamp | ||
run: | | ||
cd packages/ketchup | ||
VERSION=$(node -p "require('./package.json').version") | ||
TIMESTAMP=$(date +%Y%m%d%H%M%S) | ||
NEW_VERSION="${VERSION}-${TIMESTAMP}" | ||
echo "New version: $NEW_VERSION" | ||
sed -i "s/\"version\": \"$VERSION\"/\"version\": \"$NEW_VERSION\"/" ./package.json | ||
- name: Update Ketchup React Version with Timestamp | ||
run: | | ||
cd packages/ketchup-react | ||
VERSION=$(node -p "require('./package.json').version") | ||
TIMESTAMP=$(date +%Y%m%d%H%M%S) | ||
NEW_VERSION="${VERSION}-${TIMESTAMP}" | ||
echo "New version: $NEW_VERSION" | ||
sed -i "s/\"version\": \"$VERSION\"/\"version\": \"$NEW_VERSION\"/" ./package.json | ||
- name: Run Ketchup build | ||
run: npm run k:build | ||
|
||
- name: Publish Ketchup | ||
run: | | ||
cd packages/ketchup | ||
npm publish | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
|
||
- name: Publish Ketchup React | ||
run: | | ||
cd packages/ketchup-react | ||
npm publish | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
|
||
trigger-webup-continuum: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- run: | | ||
curl -L \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: Bearer ${{ secrets.ROBBY_SMEUP_PAT }}" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
https://api.github.com/repos/smeup/webup-project/actions/workflows/continuum.yaml/dispatches \ | ||
-d '{"ref": "develop"}' | ||
trigger-webupjs-develop: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- run: | | ||
curl -L \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: Bearer ${{ secrets.ROBBY_SMEUP_PAT }}" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
https://api.github.com/repos/smeup/webup.js/actions/workflows/develop-release.yaml/dispatches \ | ||
-d '{"ref": "develop"}' |
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
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
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
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
Oops, something went wrong.