πDeploying
Approval Process
Deploying
# Example Portal Deploy
name: Portal deploy
on:
push:
branches:
- main
jobs:
deploy:
concurrency: portal-deploy
environment: develop
runs-on: ubuntu-latest
steps:
- name: Get current date
id: date
run: echo "::set-output name=date::$(date +'%Y-%m-%dT%H:%M')"
- name: Get the current version ref
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_SHA}
- name: Checkout
uses: actions/checkout@v4
- name: Install Dependencies
run: yarn install
- name: Build
run: yarn build
env:
NODE_OPTIONS: --max-old-space-size=6144
CI: false
VITE_PORTAL_APP: "crop-boom"
VITE_PRIVATE_IMAGE_URL: "https://sunflower-land.com/game-assets"
VITE_API_URL: "https://api-dev.sunflower-land.com"
VITE_ROOM_URL: "wss://mmo-dev.sunflower-land.com"
VITE_PORTAL_GAME_URL: "https://sunflower-land.com/testnet/"
- name: Configure AWS Credentials
uses: aws-actions/[email protected]
with:
aws-access-key-id: ${{ secrets.DEPLOY_KEY_ID }}
aws-secret-access-key: ${{ secrets.DEPLOY_ACCESS_KEY }}
aws-region: ap-southeast-2
- name: Deploy static site to S3 subdomain
run: aws s3 sync ./dist/ s3://crop-boom.sunflower-land.com --deleteLast updated