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

Adds VCS for Gitlab #13

Merged
merged 2 commits into from
Mar 10, 2023
Merged

Adds VCS for Gitlab #13

merged 2 commits into from
Mar 10, 2023

Conversation

bshore
Copy link
Contributor

@bshore bshore commented Mar 9, 2023

From tilt-dev/tilt#5909 (comment) - mentions that gitlab.com host/regex is missing.

After this PR, a version bump to v0.2.3 and updating it in tilt-dev/tilt should resolve the original issue

Testing from tilt-dev/tilt

With this branch checked out, in your go.mod replace go-get with a local path

module github.com/tilt-dev/tilt

go 1.19

replace github.com/tilt-dev/go-get => /path/to/this/local/go-get

require (
  // all of the things
)

Run a go mod vendor and then make install

Sample Tiltfile

extension_path="https://gitlab.com/nicks6/tilt-extension-experiment"
v1alpha1.extension_repo(name='tilt-extension-experiment', url=extension_path, ref='main')
v1alpha1.extension(name='tilt_extension', repo_name='tilt-extension-experiment', repo_path='tilt_extension')
load('ext://tilt_extension', 'vue_build', 'dotnet_build')

vue_build("test")
test_yaml = blob("""---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: test
  labels:
    app.kubernetes.io/name: test
spec:
  selector:
    matchLabels:
      app.kubernetes.io/name: test
  template:
    metadata:
      labels:
        app.kubernetes.io/name: test
    spec:
      containers:
        - name: test
          image: test:latest
""")
k8s_yaml(test_yaml)

"$(go env GOPATH)/bin/tilt" up should find and download the gitlab extension, run vue_build("test") and start a container

Signed-off-by: bshore <shore7@gmail.com>
vcs.go Show resolved Hide resolved
Signed-off-by: bshore <shore7@gmail.com>
Copy link
Member

@nicks nicks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks!

@nicks nicks merged commit 295ccc6 into tilt-dev:master Mar 10, 2023
nicks added a commit to nicks/tilt that referenced this pull request Mar 10, 2023
adds support for gitlab modules
Pulls in tilt-dev/go-get#13
Fixes tilt-dev#5909
nicks added a commit to nicks/tilt that referenced this pull request Mar 10, 2023
adds support for gitlab modules
Pulls in tilt-dev/go-get#13
Fixes tilt-dev#5909

Signed-off-by: Nick Santos <nick.santos@docker.com>
@bshore bshore deleted the vcs-path-for-gitlab branch March 10, 2023 20:00
nicks added a commit to tilt-dev/tilt that referenced this pull request Mar 10, 2023
adds support for gitlab modules
Pulls in tilt-dev/go-get#13
Fixes #5909

Signed-off-by: Nick Santos <nick.santos@docker.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants