Wildcard updates broke non-wildcard domain #34

已关闭
由 Ghost 于 2019-04-01 19:12:59 +00:00 打开 · 6 评论

This has broken my server

Apr  1 13:39:28 ip-172-31-2-116 node: Unhandled rejection TypeError: Cannot read property 'toLowerCase' of undefined
Apr  1 13:39:28 ip-172-31-2-116 node: at /.../node_modules/greenlock/lib/utils.js:26:26
Apr  1 13:39:28 ip-172-31-2-116 node: at Array.some (<anonymous>)
Apr  1 13:39:28 ip-172-31-2-116 node: at Object.module.exports.certHasDomain (/.../node_modules/greenlock/lib/uti$
Apr  1 13:39:28 ip-172-31-2-116 node: at /.../node_modules/greenlock/lib/core.js:444:23
This has broken my server ``` Apr 1 13:39:28 ip-172-31-2-116 node: Unhandled rejection TypeError: Cannot read property 'toLowerCase' of undefined Apr 1 13:39:28 ip-172-31-2-116 node: at /.../node_modules/greenlock/lib/utils.js:26:26 Apr 1 13:39:28 ip-172-31-2-116 node: at Array.some (<anonymous>) Apr 1 13:39:28 ip-172-31-2-116 node: at Object.module.exports.certHasDomain (/.../node_modules/greenlock/lib/uti$ Apr 1 13:39:28 ip-172-31-2-116 node: at /.../node_modules/greenlock/lib/core.js:444:23 ```
管理员

Can you give me some more information? I have tests cases surrounding this that pass.

I don't doubt that my update broke it. However, I'm not sure how to reproduce. What does your config look like?

Can you give me some more information? I have tests cases surrounding this that pass. I don't doubt that my update broke it. However, I'm not sure how to reproduce. What does your config look like?
作者

Sure. I imagine these kind of bugs are a pain to track.

    const lex = require('greenlock-express').create({
      version: 'draft-11',
      server: config.ssl.staging ? 'https://acme-staging-v02.api.letsencrypt.org/directory' : 'https://acme-v02.api.letsencrypt.org/directory',
      agreeTos: true,
      configDir: config.ssl.certDir, // '~/certs/'
      email: config.ssl.email,
      communityMember: false,
      telemetry: false,
      app,
      approveDomains: config.ssl.domains // ['my.domain.com']
    })

    server = lex.listen(config.port, config.ssl.port)

Not sure what else to provide. It's been working great all this time until last update. I'm guessing _domain isn't getting passed or some test is failing.

Sure. I imagine these kind of bugs are a pain to track. ``` const lex = require('greenlock-express').create({ version: 'draft-11', server: config.ssl.staging ? 'https://acme-staging-v02.api.letsencrypt.org/directory' : 'https://acme-v02.api.letsencrypt.org/directory', agreeTos: true, configDir: config.ssl.certDir, // '~/certs/' email: config.ssl.email, communityMember: false, telemetry: false, app, approveDomains: config.ssl.domains // ['my.domain.com'] }) server = lex.listen(config.port, config.ssl.port) ``` Not sure what else to provide. It's been working great all this time until last update. I'm guessing _domain isn't getting passed or some test is failing.
管理员

I think it may be a bug in greenlock-express, actually - passing in bad data and missing the 'domain' string for the servername on startup when it isn't available yet and falling through to trying to use it anyway.

I've published greenlock@v2.7.1 with a workaround that should do until I can address the other tonight.

Please give it a try and let me know if that fixes it for you.

I think it may be a bug in greenlock-express, actually - passing in bad data and missing the 'domain' string for the servername on startup when it isn't available yet and falling through to trying to use it anyway. I've published `greenlock@v2.7.1` with a workaround that should do until I can address the other tonight. Please give it a try and let me know if that fixes it for you.
作者

Ok I'll give it a try later. Is there a way to force it to update? greenlock is a dependency of greenlock-express (which is a dependency of my project). so npm update or ci even doesn't seem to update it that deep.

Ok I'll give it a try later. Is there a way to force it to update? greenlock is a dependency of greenlock-express (which is a dependency of my project). so npm update or ci even doesn't seem to update it that deep.
管理员

greenlock-express has a package-lock.json (which is still pointing to the older version of greenlock), so npm ci should do the trick.

However, you can manually npm install --save greenlock@2.7.1 at the root of your project and that shouldn't be in conflict with greenlock-express' dependency graphy.

(otherwise we have a very strange catch 22)

greenlock-express has a `package-lock.json` (which is still pointing to the older version of `greenlock`), so `npm ci` _should_ do the trick. However, you can manually `npm install --save greenlock@2.7.1` at the root of your project and that _shouldn't_ be in conflict with `greenlock-express`' dependency graphy. (otherwise we have a very strange catch 22)
作者

That looks to have done the trick. Thanks @coola86

That looks to have done the trick. Thanks @coola86
coolaj862019-04-02 03:46:29 +00:00 关闭此工单
登录 并参与到对话中。
未选择标签
未选择里程碑
未指派成员
2 名参与者
通知
到期时间
到期日期无效或超出范围。请使用 'yyyy-mm-dd' 格式。

未设置到期时间。

依赖工单

没有设置依赖项。

参考:coolaj86/greenlock.js-ARCHIVED#34
没有提供说明。