-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* remove osweek branches from workflow files * fix typos * explicitly use python3
- Loading branch information
1 parent
81269b9
commit 01db0af
Showing
16 changed files
with
62 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ on: | |
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main, osweek23 ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ on: | |
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main, osweek23 ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ on: | |
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main, osweek23 ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ on: | |
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main, osweek23 ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,10 +23,18 @@ docker build -t theiacloud/theia-cloud-git-init:local -f dockerfiles/git-init/Do | |
```bash | ||
# don't save in ~/.ssh/... but e.g. in ~/tmp/ssh/id_theiacloud | ||
ssh-keygen -t ed25519 -C "Test TC Git Init SSH Keypair" | ||
|
||
# check if key is added already | ||
ssh-add -L | ||
|
||
# add the key if necessary | ||
ssh-add ~/tmp/ssh/id_theiacloud | ||
``` | ||
|
||
### Test Checkout with container | ||
|
||
Please also play with wrong password or public SSH Keys that are not (yet) added to the repository to get the known error cases. | ||
|
||
```bash | ||
# Adjust URLs and Password/PATs below | ||
# keep spaces in front to avoid command being added to bash history | ||
|
@@ -43,6 +51,7 @@ ssh-keygen -t ed25519 -C "Test TC Git Init SSH Keypair" | |
# HTTPS Public | ||
docker run --rm theiacloud/theia-cloud-git-init:local "$HTTP_PUBLIC" "/tmp/my-repo" "$BRANCH" | ||
|
||
# For HTTPS auth with PATs as password a lot of providers accept any username | ||
# HTTPS Private | ||
docker run --env GIT_PROMPT1=$HTTP_USERNAME --env GIT_PROMPT2=$HTTP_PASSWORD --rm theiacloud/theia-cloud-git-init:local "$HTTP_PRIVATE" "/tmp/my-repo" "$BRANCH" | ||
|
||
|
@@ -52,12 +61,31 @@ docker run --env GIT_PROMPT1=$HTTP_PASSWORD --rm theiacloud/theia-cloud-git-init | |
# HTTPS Private with Username and Password | ||
docker run --rm theiacloud/theia-cloud-git-init:local "$HTTP_PRIVATE_WITH_USERNAME_AND_PASSWORD" "/tmp/my-repo" "$BRANCH" | ||
|
||
# SSH | ||
# SSH (the expected keyname is id_theiacloud ! With a different naming pattern this command will fail. Rename/Create a copy of you keyname if necessary) | ||
docker run --env GIT_PROMPT1=$SSH_PASSWORD -v ~/tmp/ssh/:/etc/theia-cloud-ssh --rm theiacloud/theia-cloud-git-init:local "$SSH_REPO" "/tmp/my-repo" "$BRANCH" | ||
``` | ||
|
||
### Create Kubernetes Resources | ||
|
||
#### Workspace | ||
|
||
If testing on Minikube also mount a directory with expected user permissions: `minikube mount --uid 101 --gid 101 ~/tmp/minikube:/tmp/hostpath-provisioner/theia-cloud` | ||
|
||
You might have to adjust your firewall (temporarily). | ||
|
||
With below Sessions, the Workspace will be mounted inside the `persisted` subdirectory in the workspace. | ||
|
||
```yaml | ||
apiVersion: theia.cloud/v3beta | ||
kind: Workspace | ||
metadata: | ||
name: ws-asdfghjkl-theia-cloud-demo-foo-theia-cloud-io | ||
namespace: theiacloud | ||
spec: | ||
name: ws-asdfghjkl-theia-cloud-demo-foo-theia-cloud-io | ||
user: [email protected] | ||
``` | ||
#### Secret for HTTP(S) auth | ||
```yaml | ||
|
@@ -79,7 +107,7 @@ stringData: | |
#### Example Session for HTTP(S) auth | ||
```yaml | ||
apiVersion: theia.cloud/v5beta | ||
apiVersion: theia.cloud/v7beta | ||
kind: Session | ||
metadata: | ||
name: ws-asdfghjkl-theia-cloud-demo-foo-theia-cloud-io-session | ||
|
@@ -124,7 +152,7 @@ stringData: | |
#### Example Session for SSH auth | ||
```yaml | ||
apiVersion: theia.cloud/v5beta | ||
apiVersion: theia.cloud/v7beta | ||
kind: Session | ||
metadata: | ||
name: ws-asdfghjkl-theia-cloud-demo-foo-theia-cloud-io-session | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env python | ||
#!/usr/bin/env python3 | ||
import os | ||
|
||
path = "/tmp/theia-cloud-askpw" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env python | ||
#!/usr/bin/env python3 | ||
|
||
import argparse | ||
import subprocess | ||
|