Commit graph

54 commits

Author SHA1 Message Date
Joseph Schorr
6f567e0850 Add tests for build web hooks endpoint 2017-03-20 13:22:59 -04:00
Charlton Austin
d6e45e3321 fix(buildtrigger): fixed error from github api
there was a 500 being thrown every time there was a slash at the end of a directory while adding in a new trigger this stops that 500 from coming
2017-03-10 13:04:41 -05:00
Joseph Schorr
a15abd3b5c Fix API exception in trigger setup due to invalid Dockerfile path 2017-03-07 19:25:18 -05:00
Charlton Austin
e30cd931d1 feat(buildtrigger): allow use to specify dockerfile
users can only specify the folder and the
  dockerfile must be names "Dockerfile" this allows
  users to specify the file and it can be called
  "Dockerfile" or <some name>.Dockerfile
2017-03-06 21:20:17 -05:00
Joseph Schorr
81e96d6c1d Fix merge breakage 2017-03-02 16:33:47 -05:00
Joseph Schorr
c3edc3855a Fix build trigger tests 2017-02-28 17:19:17 -05:00
Joseph Schorr
b403906bc8 Fix flakiness in new tests due to change in hash seed 2017-02-28 17:19:17 -05:00
Joseph Schorr
c9bddd9c9a Remove unnecessary check 2017-02-28 17:19:17 -05:00
Joseph Schorr
e025d8c2b2 Add schema validation of namespaces and sources methods 2017-02-28 17:19:17 -05:00
Joseph Schorr
57528aa2bc Add unit testing of gitlab trigger handler 2017-02-28 17:19:17 -05:00
Joseph Schorr
84b298f36b Add missing bitbucket test 2017-02-28 17:19:17 -05:00
Joseph Schorr
497c90e7ea Add unit testing of bitbucket trigger handler 2017-02-28 17:19:17 -05:00
Joseph Schorr
ba301b401b Break common git hosts tests into their own suite 2017-02-28 17:19:17 -05:00
Joseph Schorr
c4f873ae96 Add unit testing of github trigger handler 2017-02-28 17:19:16 -05:00
Joseph Schorr
cfe231f618 Add unit testing of custom trigger handler 2017-02-28 17:19:16 -05:00
alecmerdler
a5fc7cba5f use minified AngularJS 2017-02-28 16:52:16 -05:00
Joseph Schorr
8e863b8cf5 Implement new create and manager trigger UI
Implements the new trigger setup user interface, which is now a linear workflow found on its own page, rather than a tiny modal dialog

Fixes #1187
2017-02-28 16:51:42 -05:00
Joseph Schorr
9db20ff961 Catch SSL errors due to timeouts in Github calls
Fixes https://sentry.io/coreos/backend-production/issues/219378902/
2017-02-22 13:20:04 -05:00
Joseph Schorr
a34d18b9ea Fix handling of gitlab web hooks when tagging
Gitlab doesn't send any commit information for tagging events (because... reasons), and so we have to perform the lookup ourselves to have full metadata.

Fixes #1467
2017-02-16 15:40:37 -05:00
Joseph Schorr
9600d3c2fc Make sure we never have a None default branch
Fixes #2134
2016-11-17 14:22:01 -05:00
josephschorr
c4b73318c0 Merge pull request #2126 from coreos-inc/github-empty
Fix github trigger when submitting a webhook without a head_commit
2016-11-17 12:01:59 -05:00
Joseph Schorr
8c78d967f8 Fix KeyError in Github trigger setup
Fixes #2128
2016-11-16 15:54:08 -05:00
Joseph Schorr
69e2cfad70 Fix github trigger when submitting a webhook without a head_commit
Fixes #2125
2016-11-16 14:14:17 -05:00
josephschorr
0954240ccb Merge pull request #2060 from coreos-inc/gitlab-user-exception
Fix TypeError in Gitlab trigger when user not found
2016-10-31 13:37:45 -04:00
Joseph Schorr
99ea0a9009 Fix TypeError in Gitlab trigger when user not found
Fixes #2055
2016-10-31 13:31:26 -04:00
Joseph Schorr
b0b47bbfde Fix KeyError in config when not present in BitBucket trigger
Fixes #2054
2016-10-31 13:26:58 -04:00
Joseph Schorr
26e8e241da Fix handling of Gitlab payloads with multiple commits
Gitlab sends multiple commits in the order reversed from Github. As this only broke recently, I suspect that they may have changed the ordering. This change makes the code order-agnostic to hopefully remove the problem going forward.

Fixes #1900
2016-09-30 12:14:32 +02:00
Joseph Schorr
c43173576a Fix Gitlab trigger payload bug when commits is empty
Gitlab will occasionally send trigger payloads with an empty commit list (and a null checkout_ha) for branches that have been deleted. Properly handle that case.
2016-09-30 12:03:08 +02:00
Joseph Schorr
406cd942d2 Fix manual run under bitbucket repos with many tags/branches
Fixes #1766

Depends on merging of https://github.com/coreos/py-bitbucket/pull/3 and then a regeneration of the requirements.txt
2016-08-25 18:24:35 -04:00
Joseph Schorr
626042b10a Fix exception in Gitlab trigger when project is not present
Fixes #1629
2016-07-26 15:18:43 -07:00
Evan Cordell
eba75494d9 Use new error format for auth errors (factor exceptions into module) 2016-04-11 16:22:26 -04:00
Jimmy Zelinskie
bcea268fcb use app.gitlab_trigger for config data
This includes defaults and makes the structure of the Gitlab trigger
parallel the GitHub trigger.
2016-03-18 14:56:09 -04:00
Jimmy Zelinskie
675e1799d8 remove hardcoded host in gitlab get_repository_url 2016-03-18 14:56:09 -04:00
Joseph Schorr
6a8331d305 Tests for endpoints/web and some small fixes 2016-02-05 09:45:25 +02:00
Joseph Schorr
f99e74f0a1 Support all schemas in the custom trigger
Fixes #266
2015-12-01 16:59:24 -05:00
Silas Sewell
4f9a7b3482 Fix missing GithubException ref 2015-11-04 11:19:49 -05:00
Jimmy Zelinskie
c7fba332e6 fix handling missing authors for Bitbucket
The author was accidentally always being initialized as a JSONPathDict,
thus the `if` expression following was always true.

Fixes #733.
2015-10-29 14:14:05 -04:00
Joseph Schorr
c33ae0e896 BitBucket is being slow - increase the timeout
Fixes #721
2015-10-26 14:29:29 -04:00
Quentin Machu
37a4dafe40 Use expected exception for BitBucket OAuth error
Prevents from having a 500 when BitBucket OAuth doesn't work, as it will be caught in web.py/attach_bitbucket_trigger
2015-10-22 11:24:17 -04:00
Quentin Machu
674c16bf3b Add logging on BitBucket schema validation exception
Chatty but worthy
No need to create a custom debugging web hook anymore for Bitbucket
2015-10-22 11:21:34 -04:00
Joseph Schorr
d9e001b688 Better GitHub error messaging
Fixes #612
2015-10-16 13:51:50 -04:00
Jimmy Zelinskie
7c1547221d raise a 520 for any GitLab timeouts 2015-10-13 17:34:08 -04:00
Jimmy Zelinskie
d2c4a465e3 add default HTTP timeout to GitLab
Fixes #623.
2015-10-13 14:51:28 -04:00
Jimmy Zelinskie
0e27852444 Merge pull request #631 from jzelinskie/glfix
remove network usage from GL repo URL
2015-10-13 13:46:27 -04:00
Jimmy Zelinskie
7dfe6691ec remove network usage from GL repo URL
Fixes #624.
2015-10-13 12:44:56 -04:00
Joseph Schorr
775b47c851 Make sure we have defined timeouts on all our requests out to external build services
Fixes #623
2015-10-13 11:21:53 -04:00
Joseph Schorr
eaf81959f5 Handle the case where we have lookup_user but no username 2015-09-28 17:12:56 -04:00
Joseph Schorr
18cfe676ee Fix GH schema for missing usernames and add test 2015-09-25 15:12:24 -04:00
Joseph Schorr
85ed745433 Fix bitbucket trigger validation for commits without authors 2015-09-25 12:03:21 -04:00
Jimmy Zelinskie
7372068a72 fix skipping builds with custom-git
Custom git triggers don't necessarily have commit info available. Our
code reading the commit message was under the assumption that it would
always be there.
2015-09-22 16:51:23 -04:00