-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add basic devfile and vscode settings to the repo #459
base: devspaces-3-rhel-8
Are you sure you want to change the base?
Changes from all commits
bbe2cf0
1b93874
837dba5
13d765a
9d79b1f
72409d3
3a1cd3b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Copyright (c) 2023 Red Hat, Inc. | ||
# This program and the accompanying materials are made | ||
# available under the terms of the Eclipse Public License 2.0 | ||
# which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
# | ||
# SPDX-License-Identifier: EPL-2.0 | ||
# | ||
# Contributors: | ||
# Red Hat, Inc. - initial API and implementation | ||
|
||
# This container featres tools required for Devspaces Images | ||
FROM quay.io/devfile/universal-developer-image:ubi8-latest | ||
|
||
#install Go 1.18 (needed to work with devspaces-operator) | ||
RUN cd /tmp && wget https://go.dev/dl/go1.18.6.linux-amd64.tar.gz && \ | ||
mkdir $HOME/go1.18 && \ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can we update this to go 1.20 since that's what we're using downstream? |
||
tar -xvzf go1.18.6.linux-amd64.tar.gz -C $HOME/go1.18 --strip-components 1 && \ | ||
if ! grep -q "export PATH=\$HOME/go1.18/bin:\$PATH" $HOME/.bashrc; then echo "export PATH=\$HOME/go1.18/bin:\$PATH" >> $HOME/.bashrc; fi | ||
|
||
# install goimports (needed to work with devspaces-operator) | ||
RUN $HOME/go1.18/bin/go install golang.org/x/tools/cmd/goimports@latest |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# | ||
# Copyright (c) 2023 Red Hat, Inc. | ||
# This program and the accompanying materials are made | ||
# available under the terms of the Eclipse Public License 2.0 | ||
# which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
# | ||
# SPDX-License-Identifier: EPL-2.0 | ||
# | ||
# Contributors: | ||
# Red Hat, Inc. - initial API and implementation | ||
# | ||
|
||
name: Devfile image CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'main' | ||
paths: | ||
- '.devfile.Dockerfile' | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v3 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- | ||
name: Login to quay.io | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: quay.io | ||
username: ${{ secrets.QUAY_USERNAME }} | ||
password: ${{ secrets.QUAY_PASSWORD }} | ||
- | ||
name: Build and push container | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: .devfile.Dockerfile | ||
push: true | ||
tags: quay.io/devspaces/devspaces-images-dev:latest | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should this be :next if it's CI? |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"recommendations": [ | ||
"rogalmic.bash-debug", | ||
"redhat.vscode-yaml" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What about |
||
] | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"type": "bashdb", | ||
"request": "launch", | ||
"name": "Bash-Debug (simplest configuration)", | ||
"program": "${file}" | ||
} | ||
] | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# | ||
# Copyright (c) 2023 Red Hat, Inc. | ||
# This program and the accompanying materials are made | ||
# available under the terms of the Eclipse Public License 2.0 | ||
# which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
# | ||
# SPDX-License-Identifier: EPL-2.0 | ||
# | ||
# Contributors: | ||
# Red Hat, Inc. - initial API and implementation | ||
# | ||
schemaVersion: 2.2.0 | ||
metadata: | ||
name: devspaces-images | ||
components: | ||
- name: tools | ||
container: | ||
image: quay.io/devfile/universal-developer-image:ubi8-latest | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why are you using the upstream UDI image in a devfile for the downstream UDI image? |
||
memoryRequest: 1Gi | ||
memoryLimit: 8Gi | ||
cpuLimit: '4' | ||
cpuRequest: '0.5' | ||
commands: | ||
#devspaces-operator | ||
- id: operator-go-build | ||
exec: | ||
label: Build Eclipse Che Operator binary | ||
component: tooling-container | ||
commandLine: make build | ||
workingDir: ${PROJECT_SOURCE}/devspaces-operator | ||
- id: operator-go-run | ||
exec: | ||
label: Run Eclipse Che Operator | ||
component: tooling-container | ||
commandLine: make run | ||
workingDir: ${PROJECT_SOURCE}/devspaces-operator | ||
- id: operator-go-test | ||
exec: | ||
label: Run unit tests | ||
component: tooling-container | ||
commandLine: make test | ||
workingDir: ${PROJECT_SOURCE}/devspaces-operator | ||
#devspaces-operator-bundle |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if this is something you want to see built downstream, you aren't allowed to use
FROM quay.io
in OSBS.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this image is not needed to be built downstream. It's only used as a tooling container, when this workspace will be used in Che/Devspaces