akamai / cli-property-manager

Use this Property Manager CLI to automate Akamai property changes and deployments across many environments.
Apache License 2.0
29 stars 22 forks source link

The activate command does not work #91

Closed isss802 closed 6 months ago

isss802 commented 6 months ago

Hi there,

Expected Behavior

Activate command of akamai Property-manager does not work.

CLI Version

~ akamai --version
akamai version 1.5.6
~ akamai pm --version
0.7.8-RELEASE

Actual Behavior

Check property name

akamai -s default pm list-properties -g xxxxxx -c ctr_xxxxxx | grep test-property
(node:48538) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
╒═════════════╤═════════════╤═══════════╤══════════════════════════════╤═════════════╤══════════════╤════════════════════╤════════════════╤═════════════════╕
│"Account Id" │"Contract Id"│"Group Id" │"Property Name"               │"Property Id"│"Asset Id"    │"Production Version"│"Latest Version"│"Staging Version"│
╞═════════════╪═════════════╪═══════════╪══════════════════════════════╪═════════════╪══════════════╪════════════════════╪════════════════╪═════════════════╡
│"act_xxxx"│"ctr_xxxxx"│"grp_xxxx"│"test-property"              │"prp_xxxxx" │"aid_1xxxxxxx"│69                  │72              │69               │

Activate command fails

akamai -s default pm activate --network staging -p test-property -v
[2024-03-01T11:43:26.202] [INFO] devops-prov.factory - Switching account key to: 'undefined'
[2024-03-01T11:43:26.204] [INFO] devops-prov.factory - Using credentials file: '/Users/xxxx/.edgerc', section: 'default'
(node:48961) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
PM CLI Error: 'unknown_pm_cli_property' occurred:
 Error: PM CLI property 'test-property' doesn't exist!
    at DevopsPropertyManager.getProject (/Users/xxxx/.akamai-cli/src/cli-property-manager/src/factory.js:218:27)
    at DevopsPropertyManager.promote (/Users/xxxx/.akamai-cli/src/cli-property-manager/src/devops.js:358:30)
    at activate (/Users/xxxx/.akamai-cli/src/cli-property-manager/src/pm/property_manager_cli.js:432:33)
    at module.exports (/Users/xxxx/.akamai-cli/src/cli-property-manager/src/pm/property_manager_cli.js:1182:32)
    at Object.<anonymous> (/Users/xxxx/.akamai-cli/src/cli-property-manager/bin/akamai-property-manager:19:42)
    at Module._compile (node:internal/modules/cjs/loader:1376:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1435:10)
    at Module.load (node:internal/modules/cjs/loader:1207:32)
    at Module._load (node:internal/modules/cjs/loader:1023:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:135:12)
Error details:
    Argument #0:  test-property
isss802 commented 6 months ago

This is my mistake.