A mirror URL can now be defined for git repositories in rb-gateway.
Review Request #9305 — Created Oct. 21, 2017 and updated
A
Mirror string
field was added toRepository Info
and aGetMirror
method was implemented ingit_repository.go
.LoadConfig
was modified
to handle the new mirror option, and agetMirror
function was added to
routes.go
.
httpie
was used to send agetMirror
API request to an rb-gateway
server. The plain text stored inMirror
was obtained if it was defined,
otherwise a"Mirror not defined"
message is obtained.
Description | From | Last Updated |
---|---|---|
Can we add a unit test for the mirror route? |
david |
- Description:
-
~ I've added a field
Mirror string
in theGitRepository struct
~ and in the Repo struct
. I need to test to see if Go and Json work~ the way I think they do. ~ Added
Mirror string
toRepository Info
and aGetMirror
signature to~ repositroy.go
.~ Implemented GetMirror
ingit_repository.go
.+ I also modified LoadConfig
to handle the new mirror option and added a+ getMirror
function toroutes.go
.getMirror
works, I was able to define+ a mirror in config.json and retrieve it. - Commit:
-
083edb98159313858d9190536f4341757f209dfeba771f36321f1c465e38ff9b944a56f2b0054fa6
- Diff:
-
Revision 2 (+47 -6)
Checks run (2 succeeded)
- Commit:
-
ba771f36321f1c465e38ff9b944a56f2b0054fa6a6fdde509d627b75d28a5453ee9d83549842dbcf
- Diff:
-
Revision 3 (+49 -6)
Checks run (2 succeeded)
- Summary:
-
[WIP] Adding the Mirror_URL optionAdding the Mirror_URL option
- Description:
-
~ Added
Mirror string
toRepository Info
and aGetMirror
signature to~ repositroy.go
.~ Implemented GetMirror
ingit_repository.go
.~ I also modified LoadConfig
to handle the new mirror option and added a~ A
Mirror string
field was added toRepository Info
and aGetMirror
~ method was implemented in git_repository.go
.LoadConfig
was modified~ to handle the new mirror option, and a getMirror
function was added to~ routes.go
.- getMirror
function toroutes.go
.getMirror
works, I was able to define- a mirror in config.json and retrieve it. - Testing Done:
-
+ httpie
was used to send agetMirror
API request to an rb-gateway+ server. The plain text stored in Mirror
was obtained if it was defined,+ otherwise a "Mirror not defined"
message is obtained.
- Commit:
-
a6fdde509d627b75d28a5453ee9d83549842dbcf0282c759e241e70e21a4e2656025923d758df0e5
- Diff:
-
Revision 4 (+49 -6)