Skip to content
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

Use dsc to install Dev Spaces #16

Merged
merged 5 commits into from
Mar 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions .devfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,24 @@ components:
memoryRequest: 256M
memoryLimit: 1536M
cpuRequest: 100m
cpuLimit: 500m
cpuLimit: 1500m
commands:
- id: 1-deploy-devspaces
exec:
label: "1. Deploy nightly build of Dev Spaces"
component: tooling-container
commandLine: |
commandLine: |
[[ "$(oc whoami)" =~ ^kube:admin$ ]] || (echo "You need to login as kubeadmin" && false) &&
git submodule init && git submodule update && \
git -C devspaces checkout devspaces-3-rhel-8 && \
cd devspaces/product && \
./installDevSpacesFromLatestIIB.sh --next
DSC_VERSION="3.5.0-CI"; DSC_ARCH="linux-x64"
DSC_HOME=${HOME}/.dsc; mkdir -p "${DSC_HOME}"
DSC_TGZ_URL="https://github.com/redhat-developer/devspaces-chectl/releases/download/${DSC_VERSION}-dsc-assets/devspaces-${DSC_VERSION%-*}-dsc-${DSC_ARCH}.tar.gz"
curl -sSkLo- "${DSC_TGZ_URL}" | tar -zx -C "${DSC_HOME}/" --strip-components 1
if [[ -d ${DSC_HOME}/bin ]]; then \
export PATH=${PATH%":${DSC_HOME}/bin"}:${DSC_HOME}/bin; echo -n "Installed: "; dsc version; \
else \
echo "An error occurred installing dsc $DSC_VERSION for arch $DSC_ARCH ! Check if ${DSC_TGZ_URL} is a valid file."; \
fi
dsc server:deploy --olm-channel=next --telemetry=off
- id: 2-day1-configs
exec:
label: "2. Create users, change inactivity timeout and enable container build capabilities, GitHub OAuth and image puller"
Expand Down
3 changes: 0 additions & 3 deletions .gitmodules

This file was deleted.

16 changes: 12 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,22 @@ Pre-requisites: `oc`, `jq` and `git` should be pre-installed and you should be l

```bash
# STEP 1: Install Dev Spaces next
git submodule init && git submodule update && git -C devspaces checkout devspaces-3-rhel-8 &&
cd devspaces/product && ./installDevSpacesFromLatestIIB.sh --next && \
oc patch OperatorHub cluster --type json -p '[{"op": "add", "path": "/spec/disableAllDefaultSources", "value": false}]' # re-enable default catalog sources
DSC_VERSION="3.5.0-CI"; DSC_ARCH="linux-x64"
DSC_HOME=${HOME}/.dsc; mkdir -p "${DSC_HOME}"
DSC_TGZ_URL="https://github.com/redhat-developer/devspaces-chectl/releases/download/${DSC_VERSION}-dsc-assets/devspaces-${DSC_VERSION%-*}-dsc-${DSC_ARCH}.tar.gz"
curl -sSkLo- "${DSC_TGZ_URL}" | tar -zx -C "${DSC_HOME}/" --strip-components 1
if [[ -d ${DSC_HOME}/bin ]]; then \
export PATH=${PATH%":${DSC_HOME}/bin"}:${DSC_HOME}/bin; echo -n "Installed: "; dsc version; \
else \
echo "An error occurred installing dsc $DSC_VERSION for arch $DSC_ARCH ! Check if ${DSC_TGZ_URL} is a valid file."; \
fi

dsc server:deploy --olm-channel=next
```

| :ship: NOTE |
|-------------------------------------------------------------------------------------------------------|
| If you want to install the **latest** stable release-in-progress (instead of the **next** CI build), you can use `./installDevSpacesFromLatestIIB.sh --latest`.|
| If you want to install the **latest** stable release-in-progress (instead of the **next** CI build), you can use `dsc server:deploy --olm-channel=latest'.|

```bash
# STEP 2: Day one configurations
Expand Down
1 change: 0 additions & 1 deletion devspaces
Submodule devspaces deleted from b191c1