Skip to content

Commit

Permalink
use one-liner to store license directly to auth.json
Browse files Browse the repository at this point in the history
but provide a manual step for doing it the old way
  • Loading branch information
jazzsequence committed Nov 22, 2024
1 parent dd002dd commit 58ff682
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions source/content/addons/object-cache/howto/wordpress.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,21 +117,19 @@ Refer to the [official Object Cache Pro documentation](https://objectcache.pro/d
```
1. Commit and push this file to your site.

1. Obtain a license token to use in the following authentication steps.

```bash
terminus remote:wp "<site>.<env>" -- eval "echo getenv('OCP_LICENSE');"
```

1. Create the authentication token and add your license token to Composer. You can do this automatically with the following command or create it manually with the steps below.

1. Obtain the license token and apply it directly to the Composer `auth.json` to be able to authenticate against Object Cache Pro's Composer repository.
```bash{promptUser: user}
composer config --auth http-basic.objectcache.pro token <LICENSE-TOKEN>
composer config --auth http-basic.objectcache.pro token $(terminus remote:wp <site>.<env> -- eval "echo getenv('OCP_LICENSE');")
```

This will pull the Object Cache Pro license token directly into the `auth.json` file.
**Manually:**
1. Create an `auth.json` file in your directory.
1. Run `terminus remote:wp <site>.<env> -- eval "echo getenv('OCP_LICENSE');")` to output the token to your terminal, then copy it into the `password` field in the next step.
1. Add the following code to the `auth.json` file.
Expand Down

0 comments on commit 58ff682

Please sign in to comment.