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

add gitpod setup #1020

Merged
merged 19 commits into from
Jul 31, 2022
Merged

add gitpod setup #1020

merged 19 commits into from
Jul 31, 2022

Conversation

anbraten
Copy link
Member

@anbraten anbraten commented Jul 9, 2022

Adding Gitpod allows us and others to easily start a complete Woodpecker setup and development cloud IDE. It starts a Woodpecker server, agent and a preconfigured Gitea instance. You can login at Gitea with woodpecker and password.

  • add gitpod config
  • add gitpod badge to readme
  • add gitpod to development docs
  • prepare gitea setup
    • add admin user
    • add oauth client
    • add oauth credentials to .env file

@anbraten
Copy link
Member Author

anbraten commented Jul 9, 2022

@6543 I added this Gitpod config. Gitpod is a pretty cool tool which I used a lot recently to quickly start a development of a project. Its basically a VS-Code in the cloud like Github Workspaces etc. I think it would help especially first-time contributors a lot.

The setup works already, but my idea was to automatically start a Woodpecker server & agent and a Gitea instance. To be able to automatically start Woodpecker we need the oauth credentials from Gitea. Do you know a nice way to create & get those credentials or should I simply do a super simple setup of Gitea and store that minimal setup as sqlite file to the repo?

@anbraten anbraten added the documentation docu & docs label Jul 9, 2022
@woodpecker-bot
Copy link
Collaborator

woodpecker-bot commented Jul 9, 2022

Deployment of preview was successful: https://woodpecker-ci-woodpecker-pr-1020.surge.sh

@mscherer
Copy link
Contributor

So I had the almost same problem, automate woodpecker + gitea deployment on ansible.

The next gitea version has a flag on the CLI for that exact purpose. Once you get the token, you can use curl to trigger any API call and configure gitea (so create user, create application, etc).

For example, my plan was to use "user/userCreateOAuth2Application" to create a application (and create some kind of system user).

@anbraten
Copy link
Member Author

anbraten commented Jul 13, 2022

That looks pretty cool. How did you pass the initial admin account creation and database setup screen by this? Is it gone after creating the first user 🤔

@mscherer
Copy link
Contributor

I write the app.ini file myself, using a template. The trick (if I remeber well) is to set install_lock to True. And you can create a user directly with the cli, I think

@anbraten anbraten requested a review from a team July 28, 2022 04:33
@anbraten anbraten marked this pull request as ready for review July 28, 2022 04:37
.gitpod.yml Show resolved Hide resolved
@anbraten anbraten changed the title add gitpod config add gitpod setup Jul 28, 2022
@6543 6543 added this to the 1.0.0 milestone Jul 28, 2022
@codecov-commenter
Copy link

codecov-commenter commented Jul 30, 2022

Codecov Report

Merging #1020 (6f6a5d6) into master (6351684) will increase coverage by 0.03%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master    #1020      +/-   ##
==========================================
+ Coverage   50.51%   50.55%   +0.03%     
==========================================
  Files          82       82              
  Lines        6263     6268       +5     
==========================================
+ Hits         3164     3169       +5     
  Misses       2916     2916              
  Partials      183      183              
Impacted Files Coverage Δ
server/shared/procBuilder.go 86.34% <50.00%> (+0.25%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 01bfbba...6f6a5d6. Read the comment docs.

@6543 6543 merged commit 5557674 into master Jul 31, 2022
@6543 6543 deleted the gitpod branch July 31, 2022 15:07
@qwerty287 qwerty287 added the devx label Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants