strider icon indicating copy to clipboard operation
strider copied to clipboard

`Projects/Manual Add` accepts unspecified `Repository Authentication`

Open ouadi opened this issue 9 years ago • 5 comments

Using Strider version 1.7.5, the page http://<host>:<port>/projects doesn't stop creation of a project when none of the Repository Authentication options is selected.

The created project will be unusable as access to its configuration is impossible.

ouadi avatar Oct 15 '15 12:10 ouadi

There is a WIP pull request here https://github.com/Strider-CD/strider/pull/763 that tries to tackle some of the inadequacies of this section. Your feedback is appreciated.

knownasilya avatar Oct 15 '15 12:10 knownasilya

I think that the Set default auth type is a solution given that:

  • the page rejects the config in case the repos is an ssh, http or https repos
  • strider-git can interpret it as local git repos (I have already submitted an issue for enhancement request in this regard).

ouadi avatar Oct 15 '15 13:10 ouadi

Your link doesn't work.

knownasilya avatar Oct 15 '15 14:10 knownasilya

Fixed. Sorry for any inconvenience.

ouadi avatar Oct 15 '15 14:10 ouadi

This also happens to me. Console will complain on:

strider_1 | strider stderr | /opt/strider/src/node_modules/strider-git/lib/index.js:128
strider_1 |   if (config.auth.type === 'ssh') {
strider_1 |                  ^
strider_1 | strider stderr | TypeError: Cannot read property 'type' of undefined
strider_1 |     at Object.getBranches (/opt/strider/src/node_modules/strider-git/lib/index.js:128:18)
strider_1 |     at Object.module.exports.getBranches (/opt/strider/src/node_modules/strider-git/webapp.js:33:11)
strider_1 |     at Promise.<anonymous> (/opt/strider/src/lib/routes/index.js:300:16)
strider_1 |     at Promise.<anonymous> (/opt/strider/src/node_modules/mongoose/node_modules/mpromise/lib/promise.js:177:8)
strider_1 |     at Promise.EventEmitter.emit (events.js:95:17)
strider_1 |     at Promise.emit (/opt/strider/src/node_modules/mongoose/node_modules/mpromise/lib/promise.js:84:38)
strider_1 |     at Promise.fulfill (/opt/strider/src/node_modules/mongoose/node_modules/mpromise/lib/promise.js:97:20)
strider_1 |     at /opt/strider/src/node_modules/mongoose/lib/query.js:1058:26
strider_1 |     at model.Document.init (/opt/strider/src/node_modules/mongoose/lib/document.js:254:11)
strider_1 |     at completeMany (/opt/strider/src/node_modules/mongoose/lib/query.js:1056:12)
strider_1 |     at Object.cb (/opt/strider/src/node_modules/mongoose/lib/query.js:1022:11)
strider_1 |     at Object._onImmediate (/opt/strider/src/node_modules/mongoose/node_modules/mquery/lib/utils.js:137:16)
strider_1 |     at processImmediate [as _immediateCallback] (timers.js:330:15)

But i have to point out a separed requirement that may go on another issue: there should just be a default option for authentication and it should be none.

We have internal git and there is no reason for us to give strider auth on publicly readable repos.

The UX there is quite confusing actually, you can easily guess the right sub-type looking at the protocol.

So for example you may observe url and if is http or https show a U/P form, if left blank means no auth.

if is ssh or git+ssh (or whatever implies ssh) prompt for ssh keys.

mcasimir avatar Nov 16 '15 18:11 mcasimir