Skip to content

Commit 05df486

Browse files
committed
Merge branch 'main' into ph-20250218-1257-20-percent
2 parents de7d52c + 0303ee2 commit 05df486

File tree

3 files changed

+39
-24
lines changed

3 files changed

+39
-24
lines changed

dotcom-rendering/docs/contributing/detailed-setup-guide.md

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,27 @@ For ease of development you may want to install:
6060

6161
- [React Developer Tools](https://github.com/facebook/react-devtools)
6262

63-
### Running alongside identity
63+
### Running alongside identity/sign in
6464

65-
You may want local identity cookies to be available in `dotcom-rendering`. To enable this:
65+
You may want to develop against signed in behaviour in `dotcom-rendering`.
66+
In order for this to work you have to run `dotcom-rendering` on a local domain with `https`.
6667

67-
1. run `./scripts/nginx/setup.sh`
68-
1. access `dotcom-rendering` through https://r.thegulocal.com
68+
To set this up this:
69+
70+
1. Run `./scripts/nginx/setup.sh`
71+
72+
- This will create a local domain `r.thegulocal.com` and set up a reverse proxy to `localhost:3030` with a valid SSL certificate.
73+
74+
2. `dotcom-rendering` can now be accessed through https://r.thegulocal.com when running the development server
75+
3. Sign in to https://profile.code.dev-theguardian.com/ on a separate tab/window
76+
77+
- Third party cookies must be enabled in your browser for this to work
78+
79+
4. Back on `dotcom-rendering` under https://r.thegulocal.com set a cookie with the name `GU_U` with any value on the `r.thegulocal.com` domain and refresh the page
80+
5. You should now be signed in!
81+
82+
- You should see the header change to show `My Account` instead of `Sign in`
83+
- In local storage you should see a key `gu.access_token` and `gu.id_token` with the values of the tokens you are signed in with
6984

7085
## Production
7186

dotcom-rendering/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@
4545
"@guardian/core-web-vitals": "7.0.0",
4646
"@guardian/eslint-config": "7.0.1",
4747
"@guardian/eslint-config-typescript": "9.0.1",
48-
"@guardian/identity-auth": "2.1.0",
49-
"@guardian/identity-auth-frontend": "4.0.0",
48+
"@guardian/identity-auth": "6.0.1",
49+
"@guardian/identity-auth-frontend": "8.1.0",
5050
"@guardian/libs": "20.0.0",
5151
"@guardian/ophan-tracker-js": "2.2.5",
5252
"@guardian/react-crossword": "2.0.2",

pnpm-lock.yaml

Lines changed: 18 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)