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

Initial Gitpod configuration #2406

Merged
merged 1 commit into from
Nov 1, 2021
Merged

Conversation

DukeManh
Copy link
Contributor

@DukeManh DukeManh commented Oct 27, 2021

Fixes #2393

https://www.gitpod.io/docs/getting-started#start-your-first-workspace

Issue This PR Addresses

Type of Change

  • Bugfix: Change which fixes an issue
  • New Feature: Change which adds functionality
  • Documentation Update: Change which improves documentation
  • UI: Change which improves UI

Description

Checklist

  • Quality: This PR builds and passes our npm test and works locally
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Screenshots: This PR includes screenshots or GIFs of the changes made or an explanation of why it does not (if applicable)
  • Documentation: This PR includes updated/added documentation to user exposed functionality or configuration variables are added/changed or an explanation of why it does not(if applicable)

docker/development.yml Outdated Show resolved Hide resolved
docker/docker-compose.yml Show resolved Hide resolved
@DukeManh
Copy link
Contributor Author

@humphd, @cindyledev

@humphd
Copy link
Contributor

humphd commented Oct 27, 2021

It sounds like we might want to create a separate env config for docker-compose running in gitpod, which would be similar to dev or staging. Then we can override this stuff and not affect the rest. Why don't you create docker/gitpod.yml and maybe config/gitpod.env or something, and override whatever you need in there.

@DukeManh
Copy link
Contributor Author

DukeManh commented Oct 27, 2021

It looks like we can't configre gitpod.yml location yet. It has to be the root of the repo so Gitpod knows how to find it.

I'll try to map ports to URLs in config/env.gitpod.

@humphd
Copy link
Contributor

humphd commented Oct 28, 2021

I'm saying something slightly different. You'd have 2 or 3 files:

  1. gitpod.yml in the root, as they require
  2. docker/gitpod.yml which would override our standard docker compose setup for use in GitPod
  3. config/gitpod.env which would define environment variables for use in GitPod

.gitpod.yml Show resolved Hide resolved
bin/services-build.js Outdated Show resolved Hide resolved
docker/docker-compose.yml Show resolved Hide resolved
docker/gitpod.yml Outdated Show resolved Hide resolved
docker/gitpod.yml Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
tools/services.js Outdated Show resolved Hide resolved
tools/services.js Outdated Show resolved Hide resolved
config/env.gitpod Show resolved Hide resolved
docker/development.yml Show resolved Hide resolved
.gitpod.yml Show resolved Hide resolved
docker/gitpod.yml Show resolved Hide resolved
.gitpod.yml Outdated Show resolved Hide resolved
src/web/Dockerfile Outdated Show resolved Hide resolved
@cindyorangis
Copy link
Contributor

cindyorangis commented Oct 31, 2021

I made a branch off this one to test it. I was able to get port 8000 to fetch local data https://github.com/cindyledev/telescope/tree/issue_2393_b

Unsure if I should or if I'm allowed to push commits to this branch.

To test out my branch, just click on the GitPod button to launch a GitPod environment

@cindyorangis
Copy link
Contributor

cindyorangis commented Oct 31, 2021

There are a number of things I want to test but cannot do it today as it is Halloween but I can probably get to it tomorrow. For example, I don't think we need to open so many ports, I think we only need to open up ports 3000 and 8000. And it seems like prebuild runs npm install and docker-compose --env-file config/env.gitpod up -d then it runs the same commands when you see VS Code terminal

humphd
humphd previously approved these changes Nov 1, 2021
Copy link
Contributor

@humphd humphd left a comment

Choose a reason for hiding this comment

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

File a follow-up issue to deal with getting this to work properly for the gitpod URL, and then we can take this.

@DukeManh
Copy link
Contributor Author

DukeManh commented Nov 1, 2021

Rebasing

@humphd
Copy link
Contributor

humphd commented Nov 1, 2021

@manekenpix can you take a quick look at the changes to the development/production docker files? I think this is fine, but before we merge, I want your OK. We'll get this perfected in a follow-up, but i don't want to break dev/staging/production in the meantime. Basically, you can't set ulimits in gitpod's security context (you're running docker in docker), so we need to not do this in the base config.

@humphd
Copy link
Contributor

humphd commented Nov 1, 2021

OK, discussed this with @manekenpix on Slack, and I think we're good to go with this. I'll merge.

@humphd humphd merged commit 276ceb9 into Seneca-CDOT:master Nov 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
developer experience Helping the Developer Experience hacktoberfest-accepted
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Explore using Gitpod to easily spin up development environment
3 participants