Skip to content

Code Nightly

Code Nightly #340

Workflow file for this run

name: Code Nightly
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
jobs:
create-runner:
uses: ./.github/workflows/create_runner.yml
secrets: inherit
build:
runs-on: ${{ needs.create-runner.outputs.label }}
needs: [create-runner]
container:
image: eu.gcr.io/gitpod-core-dev/dev/dev-environment:aledbf-new-dev-image-gha.13182
steps:
- uses: actions/checkout@v3
- name: Set up Google Cloud SDK
uses: google-github-actions/setup-gcloud@v0
with:
project_id: ${{ secrets.GCP_PROJECT_ID }}
- id: build-code
name: Build
env:
PR_DESC: "${{ steps.pr-details.outputs.pr_body }}"
MAIN_BRANCH: ${{ (github.head_ref || github.ref) == 'refs/heads/main' }}
run: |
export LEEWAY_WORKSPACE_ROOT=$GITHUB_WORKSPACE
gcloud auth configure-docker --quiet
codeHeadCommit=$(curl -H 'Accept: application/vnd.github.VERSION.sha' https://api.github.com/repos/gitpod-io/openvscode-server/commits/gp-code/main)
codeVersion=$(curl https://raw.githubusercontent.com/gitpod-io/openvscode-server/$codeHeadCommit/package.json | jq .version)
cd components/ide/code
leeway build \
-Dversion=nightly \
-DimageRepoBase=eu.gcr.io/gitpod-core-dev/build \
-DcodeCommit=$codeHeadCommit \
-DcodeVersion=$codeVersion \
-DcodeQuality=insider \
.:docker
- name: Get previous job's status
id: lastrun
uses: filiptronicek/get-last-job-status@main
- name: Slack Notification
if: ${{ (success() && steps.lastrun.outputs.status == 'failed') || failure() }}
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.IDE_SLACK_WEBHOOK }}
SLACK_COLOR: ${{ job.status }}
delete-runner:
if: always()
needs:
- create-runner
- build
uses: ./.github/workflows/remove_runner.yml
secrets: inherit
with:
runner-label: ${{ needs.create-runner.outputs.label }}