Back

CI/CD Pipeline Setup

CI/CD Pipeline Setup in GoSiteMe

Continuous Integration and Continuous Deployment (CI/CD) automates the process of testing and deploying your code. GoSiteMe provides built-in CI/CD pipelines that work with GoCodeMe IDE and popular Git providers. This guide walks you through setting up your first pipeline.

Overview

A CI/CD pipeline automates three key stages:

  1. Build: Compile or bundle your application.
  2. Test: Run automated tests to catch bugs before deployment.
  3. Deploy: Push the validated build to your staging or production environment.

Creating a Pipeline

  1. In your GoCodeMe IDE project, create a file called .gositeme/pipeline.yml in the project root.
  2. Define your stages:
    stages:
      - build
      - test
      - deploy
    
    build:
      script:
        - npm install
        - npm run build
      artifacts:
        paths:
          - dist/
    
    test:
      script:
        - npm run test
      coverage: /Lines\s*:\s*(\d+\.?\d*)%/
    
    deploy:
      script:
        - gositeme deploy --env production
      only:
        - main
  3. Commit and push the file. GoSiteMe detects the pipeline configuration automatically.

Supported Build Environments

GoSiteMe pipelines run in ephemeral containers with pre-installed runtimes:

  • Node.js 18, 20, 22
  • Python 3.10, 3.11, 3.12
  • PHP 8.1, 8.2, 8.3
  • Go 1.21, 1.22
  • Ruby 3.2, 3.3

Specify the runtime in your pipeline config with image: node:20 or image: python:3.12.

Environment Variables & Secrets

Store sensitive values (API keys, database credentials) under Project Settings → CI/CD → Variables. Variables are injected as environment variables during pipeline execution and are never logged in build output. Mark variables as Protected to restrict them to protected branches only.

Viewing Pipeline Results

Go to Project → Pipelines to see a list of all pipeline runs. Each run shows:

  • Status (passed, failed, running)
  • Duration and timestamp
  • Per-stage logs with expandable output
  • Test coverage report
  • Downloadable build artifacts

Notifications

Configure pipeline notifications under Project Settings → Notifications. GoSiteMe can send alerts via email, Slack, Discord, or webhook when a pipeline fails or when a deployment succeeds.

Was this answer helpful?