Giter VIP home page Giter VIP logo

redhat-backstage-build's Introduction

CI build of Backstage

Build Status Quay.io registry ghcr.io registry

Usage

This image is available in Quay.io and ghcr.io registries:

docker pull quay.io/janus-idp/redhat-backstage-build:latest
# OR
docker pull ghcr.io/janus-idp/redhat-backstage-build:latest

Minimal Backstage instance boilerplate

To get started with your own Backstage instance, follow the Getting Started instructions.

This repository uses a vanilla Backstage app created via following command:

echo backstage | npx @backstage/create-app

Docker/Podman

This repository provides a Dockerfile allowing you to build Backstage as a container based on UBI9/nodejs-18 image:

BACKSTAGE_LOCATION=<path_to_backstage>
IMAGE=<target_image_tag>

cp ./Dockerfile ./.dockerignore $BACKSTAGE_LOCATION
docker build -t $IMAGE $BACKSTAGE_LOCATION

Source-to-Image

The Backstage image can be also created via Source-to-Image.

Please install the s2i cli tool to build locally.

Using docker daemon

BACKSTAGE_LOCATION=<path_to_backstage>
IMAGE=<target_image_tag>

s2i build \
  $BACKSTAGE_LOCATION \
  --scripts-url https://raw.githubusercontent.com/janus-idp/redhat-backstage-build/main/.s2i/bin/ \
  registry.access.redhat.com/ubi9/nodejs-18:latest \
  $IMAGE

Using rootless podman

BACKSTAGE_LOCATION=<path_to_backstage>
IMAGE=<target_image_tag>

tmp_dir=$(mktemp -d)
s2i build \
  $BACKSTAGE_LOCATION \
  --scripts-url https://raw.githubusercontent.com/janus-idp/redhat-backstage-build/main/.s2i/bin/ \
  registry.access.redhat.com/ubi9/nodejs-18:latest \
  --as-dockerfile ${tmp_dir}/Containerfile

cd $tmp_dir
podman build -t $IMAGE .
rm -rf $tmp_dir

Building in OpenShift cluster

Remote builds are also possible in OpenShift. S2I can be used remotely against any Backstage repository without a local Dockerfile.

GIT_REPOSITORY=<your_backstage_instance_git_repository>
GIT_REF=<branch_or_commit>

cat << EOF | oc apply -f -
apiVersion: build.openshift.io/v1
kind: BuildConfig
metadata:
  name: backstage
spec:
  output:
    to:
      kind: ImageStreamTag
      name: backstage
  source:
    type: Git
    git:
      uri: $GIT_REPOSITORY
      ref:  $GIT_REF
  strategy:
    type: Source
    sourceStrategy:
      from:
        kind: ImageStreamTag
        name: "nodejs:latest"
        namespace: openshift
      scripts: https://raw.githubusercontent.com/redhat-developer/redhat-backstage-build/main/.s2i/bin/
  triggers:
  - type: ConfigChange
EOF

redhat-backstage-build's People

Contributors

tumido avatar sabre1041 avatar samokopecky avatar raffaelespazzoli avatar renovate[bot] avatar schultzp2020 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.