anchordotdev / cli

MIT License
297 stars 6 forks source link

Error: acme/autocert: certificate is not valid yet #46

Closed dimahoncharenko closed 1 week ago

dimahoncharenko commented 1 week ago

Are there any additional details you would like to share? I don't know what happened, I just executed the command "anchor lcl", created organization, project and so on. It's just finished of resolving domain and then... Boom! # Error! acme/autocert: certificate is not valid yet lcl

Command: anchor lcl Executable: C:\Program Files\Anchor CLI\anchor.exe Version: 0.1.7 (windows/amd64) Commit: e75e108300982a9bef8d4cc465639591335fb658 BuildDate: 2024-11-12T19:34:37Z Arguments: [] Flags: [] Timestamp: 2024-11-14T07:45:39.0712141Z Stdout:

| Let's set up fast and totally free lcl.host HTTPS!

# Setup lcl.host HTTPS Local Development Environment `anchor lcl`
    | We'll set you up to use HTTPS locally in your browsers and other programs.

# Audit lcl.host HTTPS Local Development Environment `anchor lcl audit`
    | We'll compare your local development CA certificates from Anchor and your local trust stores.
    - Compared local and expected CA certificates: no updates needed.

# Skipped: Initial System Configuration for lcl.host Local HTTPS Development `anchor lcl bootstrap`

# Setup lcl.host Application `anchor lcl setup`
    | We'll integrate your application and system for HTTPS local development.
    - Selected Create New Organization.
    - Entered happy-tails organization name.
    - Using development, the only available realm. You can also use `--realm development`.
    - No services found, so we'll create one.
    - Scanned current directory.
    - Entered javascript application server type.
    - Entered happy-tails-mantine application name.
    - Entered happy-tails-mantine.lcl.host domain for local application development.
    - Resolved happy-tails-mantine.lcl.host domain: success!
    | Now we'll provision Anchor.dev resources and HTTPS certificates for you.
    - Creating happy-tails-mantine [happy-tails-mantine.lcl.host, happy-tails-mantine.localhost] javascript resources on Anchor.dev… ⠋
dimahoncharenko commented 1 week ago

Ok, the issue is resolved. Surprisingly, I hadn't auto-synchronization of time.

geemus commented 1 week ago

@dimahoncharenko Thanks for updating to let us know. We allow a short grace period, so it usually works, but if the time on the local machine is too far off it won't. Sounds like that is what you must have seen. Glad you were able to realize that and get it fixed.