Add your Arweave gateway to Media Network
To scale up your Arweave gateway to million of users and make it available through a community-powered CDN, you can register your Arweave gateway as a resource on Media Network using the Media App front-end in 2 easy steps.
We're assuming you've already have your SPL wallet loaded with some SOL to pay for transactions fees, and at least the equivalent of 25 MEDIA (LP Tokens from Raydium's MEDIA-USDC pool count towards this) in order to use the CDN service.
Step 1 - Find out Arweave's gateway port and IP address:
In this step you'll have to find out the details about your Arweave gateway to be able to add it later on to Media Network. You can check what is running in each port by exectuing the following command:
In this case we can check that the docker container running the gateway is running on port 3000 under PID 19079
Now let's check the external IP address of your device:
In this case, we can check that the external IP address is 22.214.171.124 using the eno1 interface.
This means your Arweave gateway is running at the following URL, which is what you'll need to add as a CDN resource:
Step 2 - Add your resource to the network
Access the Media App and connect your SPL wallet.
Add your resource, specifying port number & and approve the transaction:
Finalizing the process
If everything went smoothly and the transaction was approved and confirmed, you'll see your resource ID and which origin it points to. Congrats! Your local Arweave node is now powered and scaled by Media Network. End-users accessing the new link will load the resources from Media Edges around the world instead of your original HTTP gateway.
You can test if the server and the GraphQL queries are working through Media Network's CDN by navigating to:
This webpage should look similar to.
You can now access any content hosted on the Arweave network, through your own gateway and delivered by Media Network:
Lets try to fetch the file we've just deployed
mytextfile.txt using Arweave's txID:
Or any other content: