Skip to content

Commit 0c76bb9

Browse files
authored
Removed old explore implementation (#1472)
ref https://linear.app/ghost/issue/BER-3040 Removed all code associated with the old explore implementation (generating the global static JSON, having accounts follow specific mastodon account etc.)
1 parent ddfc722 commit 0c76bb9

File tree

13 files changed

+0
-2702
lines changed

13 files changed

+0
-2702
lines changed

.github/renovate.json5

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,6 @@
2929
{
3030
"matchPackagePatterns": ["^@fedify/"],
3131
"automerge": false
32-
},
33-
{
34-
// Exclude dependencies in jobs that don't have automated tests
35-
"matchPaths": ["jobs/populate-explore-json/**"],
36-
"enabled": false
3732
}
3833
]
3934
}

.github/workflows/build.yml

Lines changed: 0 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -220,61 +220,6 @@ jobs:
220220
path: /tmp/activitypub-migrations-${{ matrix.platform_slug }}.tar
221221
retention-days: 1
222222

223-
build-populate-explore-json-job:
224-
name: Build Populate Explore JSON Job
225-
runs-on: ubuntu-latest
226-
if: github.ref == 'refs/heads/main'
227-
steps:
228-
- name: Checkout
229-
uses: actions/checkout@v4
230-
231-
- name: Check for changes in populate explore json job
232-
id: changes
233-
uses: dorny/paths-filter@v3
234-
with:
235-
filters: |
236-
populate-explore-json:
237-
- 'jobs/populate-explore-json/**'
238-
239-
- name: Set up Docker Buildx
240-
uses: docker/setup-buildx-action@v3
241-
242-
- name: Docker metadata
243-
if: steps.changes.outputs.populate-explore-json == 'true'
244-
id: populate-explore-json-meta
245-
uses: docker/metadata-action@v5
246-
with:
247-
images: europe-docker.pkg.dev/ghost-activitypub/activitypub/populate-explore-json
248-
tags: |
249-
type=sha
250-
type=edge,branch=main
251-
252-
- name: Authenticate with GCP
253-
if: steps.changes.outputs.populate-explore-json == 'true'
254-
uses: google-github-actions/auth@v2
255-
id: gcp-auth
256-
with:
257-
token_format: access_token
258-
workload_identity_provider: projects/687476608778/locations/global/workloadIdentityPools/github-oidc-activitypub/providers/github-provider-activitypub
259-
service_account: prd-activitypub-terraform-cicd@ghost-activitypub.iam.gserviceaccount.com
260-
261-
- name: Login to GCP Artifact Registry
262-
if: steps.changes.outputs.populate-explore-json == 'true'
263-
uses: docker/login-action@v3
264-
with:
265-
registry: europe-docker.pkg.dev
266-
username: oauth2accesstoken
267-
password: ${{ steps.gcp-auth.outputs.access_token }}
268-
269-
- name: Build populate explore json job image
270-
if: steps.changes.outputs.populate-explore-json == 'true'
271-
uses: docker/build-push-action@v6
272-
with:
273-
context: jobs/populate-explore-json
274-
load: true
275-
tags: ${{ steps.populate-explore-json-meta.outputs.tags }}
276-
push: true
277-
278223
build-reconcile-account-topics-job:
279224
name: Build Reconcile Account Topics Job
280225
runs-on: ubuntu-latest

features/step_definitions/index.js

Lines changed: 0 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import { getWebhookSecret } from '../support/fixtures.js';
1515
import { getCurrentDirectory } from '../support/path.js';
1616
import { fetchActivityPub } from '../support/request.js';
1717
import {
18-
getExternalWiremock,
1918
getGhostWiremock,
2019
reset as resetWiremock,
2120
} from '../support/wiremock.js';
@@ -28,7 +27,6 @@ AfterAll(async () => {
2827

2928
BeforeAll(async function setupWiremock() {
3029
const ghostActivityPub = getGhostWiremock();
31-
const externalActivityPub = getExternalWiremock();
3230

3331
const publicKey = fs.readFileSync(
3432
resolve(getCurrentDirectory(), '../fixtures/private.key'),
@@ -77,57 +75,6 @@ BeforeAll(async function setupWiremock() {
7775
},
7876
},
7977
),
80-
// Stub Ghost Explore actor on mastodon.social
81-
externalActivityPub.register(
82-
{
83-
method: 'GET',
84-
endpoint: '/users/ghostexplore',
85-
},
86-
{
87-
status: 200,
88-
body: {
89-
'@context': [
90-
'https://www.w3.org/ns/activitystreams',
91-
'https://w3id.org/security/data-integrity/v1',
92-
],
93-
id: 'https://mastodon.social/users/ghostexplore',
94-
url: 'https://mastodon.social/@ghostexplore',
95-
type: 'Service',
96-
preferredUsername: 'ghostexplore',
97-
name: 'Ghost Explore',
98-
summary:
99-
'<p>An aggregator of Ghost publications in the Fediverse</p>',
100-
inbox: 'https://mastodon.social/users/ghostexplore/inbox',
101-
outbox: 'https://mastodon.social/users/ghostexplore/outbox',
102-
followers:
103-
'https://mastodon.social/users/ghostexplore/followers',
104-
following:
105-
'https://mastodon.social/users/ghostexplore/following',
106-
liked: 'https://mastodon.social/users/ghostexplore/liked',
107-
'https://w3id.org/security#publicKey': {
108-
id: 'https://mastodon.social/users/ghostexplore#main-key',
109-
type: 'https://w3id.org/security#Key',
110-
'https://w3id.org/security#owner': {
111-
id: 'https://mastodon.social/users/ghostexplore',
112-
},
113-
'https://w3id.org/security#publicKeyPem':
114-
'-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAtSc3IqGjRaO3vcFdQ15D\nF90WVJC6tb2QwYBh9kQYVlQ1VhBiF6E4GK2okvyvukIL5PHLCgfQrfJmSiopk9Xo\n46Qri6rJbcPoWoZz/jWN0pfmU20hNuTQx6ebSoSkg6rHv1MKuy5LmDGLFC2ze3kU\nsY8u7X6TOBrifs/N+goLaH3+SkT2hZDKWJrmDyHzj043KLvXs/eiyu50M+ERoSlg\n70uO7QAXQFuLMILdy0UNJFM4xjlK6q4Jfbm4MC8QRG+i31AkmNvpY9JqCLqu0mGD\nBrdfJeN8PN+7DHW/Pzspf5RlJtlvBx1dS8Bxo2xteUyLGIaTZ9HZFhHc3IrmmKeW\naQIDAQAB\n-----END PUBLIC KEY-----\n',
115-
},
116-
},
117-
headers: {
118-
'Content-Type': 'application/activity+json',
119-
},
120-
},
121-
),
122-
externalActivityPub.register(
123-
{
124-
method: 'POST',
125-
endpoint: '/users/ghostexplore/inbox',
126-
},
127-
{
128-
status: 202,
129-
},
130-
),
13178
]);
13279
});
13380

jobs/populate-explore-json/Dockerfile

Lines changed: 0 additions & 14 deletions
This file was deleted.

jobs/populate-explore-json/README.md

Lines changed: 0 additions & 67 deletions
This file was deleted.

jobs/populate-explore-json/docker-compose.yml

Lines changed: 0 additions & 76 deletions
This file was deleted.

0 commit comments

Comments
 (0)