Merge pull request #968 from jessopb/lbrydotcom
changes lbry.io to lbry.com
This commit is contained in:
commit
992eefd40c
19 changed files with 96 additions and 77 deletions
|
@ -300,8 +300,8 @@ This project is MIT licensed. For the full license, see [LICENSE](LICENSE).
|
|||
|
||||
## Security
|
||||
|
||||
We take security seriously. Please contact security@lbry.io regarding any security issues. [Our GPG key is here](https://lbry.io/faq/gpg-key) if you need it.
|
||||
We take security seriously. Please contact security@lbry.com regarding any security issues. [Our GPG key is here](https://lbry.com/faq/gpg-key) if you need it.
|
||||
|
||||
## Contact
|
||||
|
||||
The primary contact for this project is [@jessopb](mailto:jessop@lbry.io).
|
||||
The primary contact for this project is [@jessopb](mailto:jessop@lbry.com).
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"host": "public.chainquery.lbry.io",
|
||||
"host": "public.chainquery.lbry.com",
|
||||
"port": "3306",
|
||||
"timeout": 30,
|
||||
"database": "chainquery",
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
"host": "https://www.example.com",
|
||||
"description": "A decentralized hosting platform built on LBRY",
|
||||
"twitter": false,
|
||||
"blockListEndpoint": "https://api.lbry.io/file/list_blocked"
|
||||
"blockListEndpoint": "https://api.lbry.com/file/list_blocked"
|
||||
},
|
||||
"publishing": {
|
||||
"primaryClaimAddress": null,
|
||||
|
|
|
@ -14,10 +14,10 @@ const AboutSpeechDetails = () => {
|
|||
</Row>
|
||||
<Row>
|
||||
<p className={'text--large'}>
|
||||
Spee.ch is a media-hosting site that reads from and publishes content to the <a className='link--primary' href='https://lbry.io'>LBRY</a> blockchain.
|
||||
Spee.ch is a media-hosting site that reads from and publishes content to the <a className='link--primary' href='https://lbry.com'>LBRY</a> blockchain.
|
||||
</p>
|
||||
<p className={'text--large'}>
|
||||
Spee.ch is a hosting service, but with the added benefit that it stores your content on a decentralized network of computers -- the <a className='link--primary' href='https://lbry.io/get'>LBRY</a> network. This means that your images are stored in multiple locations without a single point of failure.
|
||||
Spee.ch is a hosting service, but with the added benefit that it stores your content on a decentralized network of computers -- the <a className='link--primary' href='https://lbry.com/get'>LBRY</a> network. This means that your images are stored in multiple locations without a single point of failure.
|
||||
</p>
|
||||
</Row>
|
||||
<Row>
|
||||
|
@ -26,7 +26,7 @@ const AboutSpeechDetails = () => {
|
|||
If you have an idea for your own spee.ch-like site on top of LBRY, fork our <a className='link--primary' href='https://github.com/lbryio/spee.ch'>github repo</a> and go to town!
|
||||
</p>
|
||||
<p className={'text--large'}>
|
||||
If you want to improve spee.ch, join our <a className='link--primary' href='https://chat.lbry.io'>discord channel</a> or solve one of our <a className='link--primary' href='https://github.com/lbryio/spee.ch/issues'>github issues</a>.
|
||||
If you want to improve spee.ch, join our <a className='link--primary' href='https://chat.lbry.com'>discord channel</a> or solve one of our <a className='link--primary' href='https://github.com/lbryio/spee.ch/issues'>github issues</a>.
|
||||
</p>
|
||||
</Row>
|
||||
</div>
|
||||
|
|
|
@ -3,9 +3,13 @@ import Row from '@components/Row';
|
|||
|
||||
const AssetInfoFooter = ({ assetUrl, name }) => {
|
||||
return (
|
||||
<div className='asset-footer'>
|
||||
<div className="asset-footer">
|
||||
<p>
|
||||
Hosted via the <a className={'link--primary'} href={'https://lbry.io/get'} target={'_blank'}>LBRY</a> blockchain
|
||||
Hosted via the{' '}
|
||||
<a className={'link--primary'} href={'https://lbry.com/get'} target={'_blank'}>
|
||||
LBRY
|
||||
</a>{' '}
|
||||
blockchain
|
||||
</p>
|
||||
</div>
|
||||
);
|
||||
|
|
|
@ -3,7 +3,7 @@ import React from 'react';
|
|||
const PublishFinePrint = () => {
|
||||
return (
|
||||
<p className={'text--extra-small text--secondary'}>
|
||||
By clicking 'Publish', you affirm that you have the rights to publish this content to the LBRY network, and that you understand the properties of publishing it to a decentralized, user-controlled network. <a className='link--primary' target='_blank' href='https://lbry.io/learn'>Read more.</a>
|
||||
By clicking 'Publish', you affirm that you have the rights to publish this content to the LBRY network, and that you understand the properties of publishing it to a decentralized, user-controlled network. <a className='link--primary' target='_blank' href='https://lbry.com/learn'>Read more.</a>
|
||||
</p>
|
||||
);
|
||||
};
|
||||
|
|
|
@ -17,7 +17,7 @@ class BlockedRight extends React.PureComponent {
|
|||
return (
|
||||
<div className={'asset-blocked__text'} >
|
||||
<p>In response to a complaint we received under the US Digital Millennium Copyright Act, we have blocked access to this content from our applications.</p>
|
||||
<p><a href={'https://lbry.io/faq/dmca'} >Click here</a> for more information.</p>
|
||||
<p><a href={'https://lbry.com/faq/dmca'} >Click here</a> for more information.</p>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
@ -76,7 +76,7 @@ class AssetDisplay extends React.Component {
|
|||
<div>
|
||||
<p>Sit tight, we're searching the LBRY blockchain for your asset!</p>
|
||||
<ProgressBar size={12} />
|
||||
<p>Curious what magic is happening here? <a className='link--primary' target='blank' href='https://lbry.io/faq/what-is-lbry'>Learn more.</a></p>
|
||||
<p>Curious what magic is happening here? <a className='link--primary' target='blank' href='https://lbry.com/faq/what-is-lbry'>Learn more.</a></p>
|
||||
</div>
|
||||
}
|
||||
{(status === ERROR) && (
|
||||
|
@ -87,7 +87,7 @@ class AssetDisplay extends React.Component {
|
|||
) : (
|
||||
<div>
|
||||
<Row>
|
||||
<p>Unfortunately, we couldn't download your asset from LBRY. You can help us out by sharing the following error message in the <a className='link--primary' href='https://chat.lbry.io' target='_blank'>LBRY discord</a>.</p>
|
||||
<p>Unfortunately, we couldn't download your asset from LBRY. You can help us out by sharing the following error message in the <a className='link--primary' href='https://chat.lbry.com' target='_blank'>LBRY discord</a>.</p>
|
||||
</Row>
|
||||
<Row>
|
||||
<p id='error-message'><i>{error}</i></p>
|
||||
|
|
|
@ -186,7 +186,7 @@ class AssetInfo extends React.Component {
|
|||
</a>
|
||||
<a
|
||||
className={'link--primary'}
|
||||
href={`https://open.lbry.io/${createPermanentURI(asset)}`}
|
||||
href={`https://open.lbry.com/${createPermanentURI(asset)}`}
|
||||
download={name}
|
||||
>
|
||||
LBRY URL
|
||||
|
@ -194,7 +194,7 @@ class AssetInfo extends React.Component {
|
|||
<a
|
||||
className={'link--primary'}
|
||||
target='_blank'
|
||||
href='https://lbry.io/dmca'
|
||||
href='https://lbry.com/dmca'
|
||||
>
|
||||
Report
|
||||
</a>
|
||||
|
|
|
@ -38,7 +38,7 @@ class PublishStatus extends React.Component {
|
|||
<ProgressBar size={12} />
|
||||
</Row>
|
||||
<Row>
|
||||
<p>Curious what magic is happening here? <a className='link--primary' target='blank' href='https://lbry.io/faq/what-is-lbry'>Learn more.</a></p>
|
||||
<p>Curious what magic is happening here? <a className='link--primary' target='blank' href='https://lbry.com/faq/what-is-lbry'>Learn more.</a></p>
|
||||
</Row>
|
||||
</div>
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ class PublishStatus extends React.Component {
|
|||
<p className={'text--strong'}>{message}</p>
|
||||
</Row>
|
||||
<Row>
|
||||
<p>For help, post the above error text in the #speech channel on the <a className='link--primary' href='https://chat.lbry.io' target='_blank'>lbry discord</a></p>
|
||||
<p>For help, post the above error text in the #speech channel on the <a className='link--primary' href='https://chat.lbry.com' target='_blank'>lbry discord</a></p>
|
||||
</Row>
|
||||
<Row>
|
||||
<ButtonSecondary
|
||||
|
|
|
@ -15,7 +15,7 @@ class FaqPage extends React.Component {
|
|||
</Row>
|
||||
<Row>
|
||||
<h3>What is spee.ch?</h3>
|
||||
<p>Spee.ch is a media-hosting site that reads from and publishes content to the <a href='http://lbry.io/'>LBRY blockchain</a>.</p>
|
||||
<p>Spee.ch is a media-hosting site that reads from and publishes content to the <a href='http://lbry.com/'>LBRY blockchain</a>.</p>
|
||||
</Row>
|
||||
<Row>
|
||||
<h3>OK But Why Should I Care?</h3>
|
||||
|
@ -38,7 +38,7 @@ class FaqPage extends React.Component {
|
|||
<Row>
|
||||
<h3>Contribute</h3>
|
||||
<p>If you have an idea for your own spee.ch-like site on top of LBRY, fork our <a href='https://github.com/lbryio/spee.ch'>github repo</a> and go to town!</p>
|
||||
<p>If you want to improve spee.ch, join <a href='https://chat.lbry.io/'>our discord channel</a> or solve one of our <a href='https://github.com/lbryio/spee.ch/issues'>github issues</a>.</p>
|
||||
<p>If you want to improve spee.ch, join <a href='https://chat.lbry.com/'>our discord channel</a> or solve one of our <a href='https://github.com/lbryio/spee.ch/issues'>github issues</a>.</p>
|
||||
</Row>
|
||||
</Row>
|
||||
</PageLayout>
|
||||
|
|
|
@ -7,7 +7,7 @@ const MultisiteContent = () => {
|
|||
<p className='text--pull-quote'>Introducing Spee.ch Multisite</p>
|
||||
<p>Hi there! My name is <a href={'https://github.com/billbitt'} target={'_blank'}>Bill</a>, and I’d like to speak with you about Spee.ch. No, not ‘speech,’ ‘<i><a href={'https://spee.ch'} target={'_blank'}>Spee.ch.</a></i>’ You know what, just read on...</p>
|
||||
<h2>A Little Background</h2>
|
||||
<p>Wow, time flies! A little over a year ago Spee.ch was nothing more than a glimmer in the eye of LBRY CEO Jeremy Kaufman. At that time, the <a href={'https://lbry.io/faq/what-is-lbry'} target={'_blank'}>LBRY protocol</a> was still so early in its development, that there were no web-based applications for interacting with the LBRY blockchain. But then, something beautiful happened. On March 29th, 2017, Jeremy sat down with Jack, and together they <a href={'https://www.youtube.com/watch?v=C9LCapt_OYw'} target={'_blank'}>live coded a single-page PHP site</a> that could publish images to the LBRY network. And just like that, Spee.ch was born!</p>
|
||||
<p>Wow, time flies! A little over a year ago Spee.ch was nothing more than a glimmer in the eye of LBRY CEO Jeremy Kaufman. At that time, the <a href={'https://lbry.com/faq/what-is-lbry'} target={'_blank'}>LBRY protocol</a> was still so early in its development, that there were no web-based applications for interacting with the LBRY blockchain. But then, something beautiful happened. On March 29th, 2017, Jeremy sat down with Jack, and together they <a href={'https://www.youtube.com/watch?v=C9LCapt_OYw'} target={'_blank'}>live coded a single-page PHP site</a> that could publish images to the LBRY network. And just like that, Spee.ch was born!</p>
|
||||
<p>Being that LBRY is an open source project, Jeremy ended the session by inviting community members who were interested in the project to take the reigns and see where Spee.ch could go. I was one of the devs that did just that, and it wasn’t long before I was on a weekly call dedicated to this project with contributors from around the world.</p>
|
||||
<p>At this point in time, the vision for Spee.ch was pretty simple: create a web-based hosting service that used the LBRY network as a database for free image and video sharing. In other words, an ‘imgur on the blockchain.’</p>
|
||||
<h2>Growth</h2>
|
||||
|
@ -41,7 +41,7 @@ const MultisiteContent = () => {
|
|||
<li>Where: Google Hangouts</li>
|
||||
<li>Link: <a href={'https://meet.google.com/aex-ghqg-kcs'} target={'_blank'}>meet.google.com/aex-ghqg-kcs</a></li>
|
||||
<li>System Requirements: If you have a server, please make sure you have MySql, Node and NPM installed. If you need help installing the above, or if you need a server to run your own instance on, please join the Hangout 30 minutes ahead of time and we will help get you set up =]</li>
|
||||
<li>Questions: hello@lbry.io</li>
|
||||
<li>Questions: hello@lbry.com</li>
|
||||
</ul>
|
||||
</div>
|
||||
);
|
||||
|
|
|
@ -9,7 +9,7 @@ const AssetLiteFooter = ({ name, claimId }) => {
|
|||
return (
|
||||
<SpaceAround>
|
||||
<p className={'text--extra-small'}>
|
||||
<Link className='link--primary' to={`/${claimId}/${name}`}> hosted on spee.ch</Link> via the <a className='link--primary' href={'https://lbry.io/get'} target={'_blank'}>LBRY</a> blockchain
|
||||
<Link className='link--primary' to={`/${claimId}/${name}`}> hosted on spee.ch</Link> via the <a className='link--primary' href={'https://lbry.com/get'} target={'_blank'}>LBRY</a> blockchain
|
||||
</p>
|
||||
</SpaceAround>
|
||||
);
|
||||
|
|
|
@ -13,15 +13,15 @@ class TosPage extends React.Component {
|
|||
<Row>
|
||||
<h1>Terms of Service</h1>
|
||||
<p>Last updated: September 25, 2018</p>
|
||||
<p>Please read these Terms of Service ("Terms", "Terms of Service") carefully before using the <a className='link--primary' href='https://spee.ch'>https://spee.ch</a> website (the "Service") operated by <a className='link--primary' href='https://lbry.io'>LBRY INC</a> ("us", "we", or "our").</p>
|
||||
<p>Please read these Terms of Service ("Terms", "Terms of Service") carefully before using the <a className='link--primary' href='https://spee.ch'>https://spee.ch</a> website (the "Service") operated by <a className='link--primary' href='https://lbry.com'>LBRY INC</a> ("us", "we", or "our").</p>
|
||||
<p>Your access to and use of the Service is conditioned upon your acceptance of and compliance with these Terms. These Terms apply to all visitors, users and others who wish to access or use the Service.</p>
|
||||
<p>By accessing or using the Service you agree to be bound by these Terms. If you disagree with any part of the terms then you do not have permission to access the Service.</p>
|
||||
</Row>
|
||||
<Row>
|
||||
<h3>Links To Other Web Sites</h3>
|
||||
<p>Our Service may contain links to third party web sites or services that are not owned or controlled by <a className='link--primary' href='https://lbry.io'>LBRY INC</a></p>
|
||||
<p><a className='link--primary' href='https://lbry.io'>LBRY INC</a> has no control over, and assumes no responsibility for the content, privacy policies, or practices of any third party web sites or services. We do not warrant the offerings of any of these entities/individuals or their websites.</p>
|
||||
<p>You acknowledge and agree that <a className='link--primary' href='https://lbry.io'>LBRY INC</a> shall not be responsible or liable, directly or indirectly, for any damage or loss caused or alleged to be caused by or in connection with use of or reliance on any such content, goods or services available on or through any such third party web sites or services.</p>
|
||||
<p>Our Service may contain links to third party web sites or services that are not owned or controlled by <a className='link--primary' href='https://lbry.com'>LBRY INC</a></p>
|
||||
<p><a className='link--primary' href='https://lbry.com'>LBRY INC</a> has no control over, and assumes no responsibility for the content, privacy policies, or practices of any third party web sites or services. We do not warrant the offerings of any of these entities/individuals or their websites.</p>
|
||||
<p>You acknowledge and agree that <a className='link--primary' href='https://lbry.com'>LBRY INC</a> shall not be responsible or liable, directly or indirectly, for any damage or loss caused or alleged to be caused by or in connection with use of or reliance on any such content, goods or services available on or through any such third party web sites or services.</p>
|
||||
<p>We strongly advise you to read the terms and conditions and privacy policies of any third party web sites or services that you visit.</p>
|
||||
</Row>
|
||||
<Row>
|
||||
|
@ -35,12 +35,12 @@ class TosPage extends React.Component {
|
|||
</Row>
|
||||
<Row>
|
||||
<h3>Limitation Of Liability</h3>
|
||||
<p>In no event shall <a className='link--primary' href='https://lbry.io'>LBRY INC</a>, nor its directors, employees, partners, agents, suppliers, or affiliates, be liable for any indirect, incidental, special, consequential or punitive damages, including without limitation, loss of profits, data, use, goodwill, or other intangible losses, resulting from (i) your access to or use of or inability to access or use the Service; (ii) any conduct or content of any third party on the Service; (iii) any content obtained from the Service; and (iv) unauthorized access, use or alteration of your transmissions or content, whether based on warranty, contract, tort (including negligence) or any other legal theory, whether or not we have been informed of the possibility of such damage, and even if a remedy set forth herein is found to have failed of its essential purpose.</p>
|
||||
<p>In no event shall <a className='link--primary' href='https://lbry.com'>LBRY INC</a>, nor its directors, employees, partners, agents, suppliers, or affiliates, be liable for any indirect, incidental, special, consequential or punitive damages, including without limitation, loss of profits, data, use, goodwill, or other intangible losses, resulting from (i) your access to or use of or inability to access or use the Service; (ii) any conduct or content of any third party on the Service; (iii) any content obtained from the Service; and (iv) unauthorized access, use or alteration of your transmissions or content, whether based on warranty, contract, tort (including negligence) or any other legal theory, whether or not we have been informed of the possibility of such damage, and even if a remedy set forth herein is found to have failed of its essential purpose.</p>
|
||||
</Row>
|
||||
<Row>
|
||||
<h3>Disclaimer</h3>
|
||||
<p>Your use of the Service is at your sole risk. The Service is provided on an "AS IS" and "AS AVAILABLE" basis. The Service is provided without warranties of any kind, whether express or implied, including, but not limited to, implied warranties of merchantability, fitness for a particular purpose, non-infringement or course of performance.</p>
|
||||
<p><a className='link--primary' href='https://lbry.io'>LBRY INC</a> its subsidiaries, affiliates, and its licensors do not warrant that a) the Service will function uninterrupted, secure or available at any particular time or location; b) any errors or defects will be corrected; c) the Service is free of viruses or other harmful components; or d) the results of using the Service will meet your requirements.</p>
|
||||
<p><a className='link--primary' href='https://lbry.com'>LBRY INC</a> its subsidiaries, affiliates, and its licensors do not warrant that a) the Service will function uninterrupted, secure or available at any particular time or location; b) any errors or defects will be corrected; c) the Service is free of viruses or other harmful components; or d) the results of using the Service will meet your requirements.</p>
|
||||
</Row>
|
||||
<Row>
|
||||
<h3>Exclusions</h3>
|
||||
|
@ -58,7 +58,7 @@ class TosPage extends React.Component {
|
|||
</Row>
|
||||
<Row>
|
||||
<h3>Contact Us</h3>
|
||||
<p>If you have any questions about these Terms, please <a className='link--primary' href='mailto:hello@lbry.io'>contact us</a>.</p>
|
||||
<p>If you have any questions about these Terms, please <a className='link--primary' href='mailto:hello@lbry.com'>contact us</a>.</p>
|
||||
</Row>
|
||||
</Row>
|
||||
</PageLayout>
|
||||
|
|
77
fullstart.md
77
fullstart.md
|
@ -1,51 +1,55 @@
|
|||
# Create Your Own Spee.ch!
|
||||
|
||||
## 1. Prerequisites
|
||||
|
||||
### You will need the following tools installed
|
||||
|
||||
* Node (v8 LTS).
|
||||
* Make sure you install from the **Node** website [link](https://nodejs.org/en/download/).
|
||||
* npm (should come installed with Node).
|
||||
* Git
|
||||
* Curl
|
||||
* Tmux
|
||||
* Unzip
|
||||
- Node (v8 LTS).
|
||||
- Make sure you install from the **Node** website [link](https://nodejs.org/en/download/).
|
||||
- npm (should come installed with Node).
|
||||
- Git
|
||||
- Curl
|
||||
- Tmux
|
||||
- Unzip
|
||||
|
||||
### Make sure **npm** is up-to-date.
|
||||
|
||||
```
|
||||
$ npm update
|
||||
```
|
||||
|
||||
### Setup a Webserver to serve **Spee.ch** from Port **3000**.
|
||||
* If you are using a server provided by **lbry**, we will have **caddy** installed already.
|
||||
* If you are using your own server, make sure to have a web server installed and set up to serve from port **3000**.
|
||||
* Nginx instructions (recommended).
|
||||
* Insert directions for certbot before installing.
|
||||
* Install [Nginx](http://nginx.org/en/docs/install.html).
|
||||
* Create a config file called `spee.ch` in */etc/nginx/sites-available*
|
||||
* see example: [config file](https://github.com/lbryio/spee.ch/blob/master/nginx_example_config).
|
||||
* Rename all mentions of *sub.domain.com* with your subdomain name.
|
||||
* Run this command to link the sites-available.
|
||||
|
||||
- If you are using a server provided by **lbry**, we will have **caddy** installed already.
|
||||
- If you are using your own server, make sure to have a web server installed and set up to serve from port **3000**.
|
||||
- Nginx instructions (recommended).
|
||||
|
||||
- Insert directions for certbot before installing.
|
||||
- Install [Nginx](http://nginx.org/en/docs/install.html).
|
||||
- Create a config file called `spee.ch` in _/etc/nginx/sites-available_
|
||||
- see example: [config file](https://github.com/lbryio/spee.ch/blob/master/nginx_example_config).
|
||||
- Rename all mentions of _sub.domain.com_ with your subdomain name.
|
||||
- Run this command to link the sites-available.
|
||||
|
||||
`$ ln -s /etc/nginx/sites-available/speech /etc/nginx/sites-enabled/speech`
|
||||
|
||||
* Restart Nginx.
|
||||
- Restart Nginx.
|
||||
|
||||
`$ sudo service nginx restart`
|
||||
|
||||
* Try visiting your website.
|
||||
* If Nginx is working, you should get a **502** error because there is nothing running on **3000** yet.
|
||||
* If you get the default Nginx greeting, you have not properly configured it to serve from port **3000**.
|
||||
* You can find logs in */var/log/nginx/* too.
|
||||
* Caddy tutorial: [https://caddyserver.com/tutorial](https://caddyserver.com/tutorial)
|
||||
- Try visiting your website.
|
||||
- If Nginx is working, you should get a **502** error because there is nothing running on **3000** yet.
|
||||
- If you get the default Nginx greeting, you have not properly configured it to serve from port **3000**.
|
||||
- You can find logs in _/var/log/nginx/_ too.
|
||||
- Caddy tutorial: [https://caddyserver.com/tutorial](https://caddyserver.com/tutorial)
|
||||
|
||||
### MySql
|
||||
|
||||
* Install MySql
|
||||
* [Instructions](https://dev.mysql.com/doc/mysql-installation-excerpt/5.7/en)
|
||||
* Create user **root**.
|
||||
* Note: We are going to access **mysql** as **root** for this setup, but you may want to create a separate user in the future.
|
||||
* Keep your password somewhere handy!
|
||||
* Create a database called **lbry** and make sure you can use it.
|
||||
- Install MySql
|
||||
- [Instructions](https://dev.mysql.com/doc/mysql-installation-excerpt/5.7/en)
|
||||
- Create user **root**. \* Note: We are going to access **mysql** as **root** for this setup, but you may want to create a separate user in the future.
|
||||
- Keep your password somewhere handy!
|
||||
- Create a database called **lbry** and make sure you can use it.
|
||||
|
||||
`CREATE DATABASE lbry;`
|
||||
|
||||
|
@ -53,22 +57,26 @@ $ npm update
|
|||
|
||||
`$ exit; (or press ‘ctl + d’)`
|
||||
|
||||
* Try logging into mysql.
|
||||
- Try logging into mysql.
|
||||
|
||||
`$ mysql -u username -p`
|
||||
|
||||
* If you are using a **LBRY** server, your **password** is the one provided for **ssh**.
|
||||
* Note: If it fails, try using `sudo`.
|
||||
- If you are using a **LBRY** server, your **password** is the one provided for **ssh**.
|
||||
- Note: If it fails, try using `sudo`.
|
||||
|
||||
##2. Install & Run the LBRY Daemon
|
||||
|
||||
### Install **lbrynet**
|
||||
|
||||
_note: if you have a server from LBRY, lbrynet is already installed, you can skip to 2.4._
|
||||
|
||||
```
|
||||
$ wget --quiet -O ~/latest_daemon.zip https://lbry.io/get/lbrynet.linux.zip
|
||||
$ wget --quiet -O ~/latest_daemon.zip https://lbry.com/get/lbrynet.linux.zip
|
||||
$ unzip -o -u "~/latest_daemon.zip"
|
||||
```
|
||||
|
||||
### Start lbrynet
|
||||
|
||||
```
|
||||
$ tmux
|
||||
$ ./lbrynet-daemon
|
||||
|
@ -127,6 +135,7 @@ $ npm run configure
|
|||
```
|
||||
|
||||
Check your site configs
|
||||
|
||||
```
|
||||
$ cd /site/config/
|
||||
$ nano siteConfig.json
|
||||
|
@ -135,6 +144,7 @@ $ nano siteConfig.json
|
|||
### Build & run
|
||||
|
||||
Run the below command to transpile, build, and start your server.
|
||||
|
||||
```
|
||||
$ npm run start
|
||||
```
|
||||
|
@ -145,17 +155,18 @@ Spee.ch should now be running !
|
|||
|
||||
Visit your site in the browser. Try publishing an image!
|
||||
|
||||
|
||||
## 4. Bonus:
|
||||
|
||||
### Install PM2 and run your server with PM2
|
||||
|
||||
Install PM2
|
||||
|
||||
```
|
||||
$ sudo npm i -g pm2
|
||||
```
|
||||
|
||||
From inside your project’s folder, start your server with PM2.
|
||||
|
||||
```
|
||||
$ pm2 start server.js
|
||||
```
|
||||
|
|
|
@ -36,7 +36,7 @@ const claimLongId = ({ ip, originalUrl, body, params }, res) => {
|
|||
return db.Blocked.isNotBlocked(outpoint);
|
||||
})
|
||||
.then(() => {
|
||||
res.status(200).json({success: true, data: claimId});
|
||||
res.status(200).json({ success: true, data: claimId });
|
||||
})
|
||||
.catch(error => {
|
||||
if (error === NO_CLAIM) {
|
||||
|
@ -54,7 +54,8 @@ const claimLongId = ({ ip, originalUrl, body, params }, res) => {
|
|||
if (error === BLOCKED_CLAIM) {
|
||||
return res.status(410).json({
|
||||
success: false,
|
||||
message: 'In response to a complaint we received under the US Digital Millennium Copyright Act, we have blocked access to this content from our applications. For more details, see https://lbry.io/faq/dmca',
|
||||
message:
|
||||
'In response to a complaint we received under the US Digital Millennium Copyright Act, we have blocked access to this content from our applications. For more details, see https://lbry.com/faq/dmca',
|
||||
});
|
||||
}
|
||||
handleErrorResponse(originalUrl, ip, error, res);
|
||||
|
|
|
@ -118,7 +118,7 @@ const getClaimIdAndServeAsset = (
|
|||
return res.status(451).json({
|
||||
success: false,
|
||||
message:
|
||||
'In response to a complaint we received under the US Digital Millennium Copyright Act, we have blocked access to this content from our applications. For more details, see https://lbry.io/faq/dmca',
|
||||
'In response to a complaint we received under the US Digital Millennium Copyright Act, we have blocked access to this content from our applications. For more details, see https://lbry.com/faq/dmca',
|
||||
});
|
||||
}
|
||||
if (error === NO_FILE) {
|
||||
|
|
|
@ -75,7 +75,7 @@ function Server() {
|
|||
res
|
||||
.status(403)
|
||||
.send(
|
||||
'<h1>Forbidden</h1>If you are seeing this by mistake, please contact us using <a href="https://chat.lbry.io/">https://chat.lbry.io/</a>'
|
||||
'<h1>Forbidden</h1>If you are seeing this by mistake, please contact us using <a href="https://chat.lbry.com/">https://chat.lbry.com/</a>'
|
||||
);
|
||||
res.end();
|
||||
} else {
|
||||
|
@ -195,7 +195,7 @@ function Server() {
|
|||
'Continuing with default LBRY blocklist api endpoint. \n ' +
|
||||
'(Specify /"blockListEndpoint" : ""/ to disable.'
|
||||
);
|
||||
finalBlockListEndpoint = 'https://api.lbry.io/file/list_blocked';
|
||||
finalBlockListEndpoint = 'https://api.lbry.com/file/list_blocked';
|
||||
}
|
||||
}
|
||||
logger.info(`Peforming updates...`);
|
||||
|
|
|
@ -1,9 +1,12 @@
|
|||
const fs = require('fs');
|
||||
|
||||
const logger = require('winston');
|
||||
const { publishing: { publishingChannelWhitelist } } = require('@config/siteConfig');
|
||||
const {
|
||||
publishing: { publishingChannelWhitelist },
|
||||
} = require('@config/siteConfig');
|
||||
const ipBanFile = './site/config/ipBan.txt';
|
||||
const forbiddenMessage = '<h1>Forbidden</h1>If you are seeing this by mistake, please contact us using <a href="https://chat.lbry.io/">https://chat.lbry.io/</a>';
|
||||
const forbiddenMessage =
|
||||
'<h1>Forbidden</h1>If you are seeing this by mistake, please contact us using <a href="https://chat.lbry.com/">https://chat.lbry.com/</a>';
|
||||
|
||||
let ipCounts = {};
|
||||
let blockedAddresses = [];
|
||||
|
@ -13,7 +16,7 @@ if (fs.existsSync(ipBanFile)) {
|
|||
input: require('fs').createReadStream(ipBanFile),
|
||||
});
|
||||
|
||||
lineReader.on('line', (line) => {
|
||||
lineReader.on('line', line => {
|
||||
if (line && line !== '') {
|
||||
blockedAddresses.push(line);
|
||||
}
|
||||
|
@ -30,7 +33,7 @@ const autoblockPublishMiddleware = (req, res, next) => {
|
|||
return;
|
||||
}
|
||||
|
||||
let count = ipCounts[ip] = (ipCounts[ip] || 0) + 1;
|
||||
let count = (ipCounts[ip] = (ipCounts[ip] || 0) + 1);
|
||||
|
||||
setTimeout(() => {
|
||||
if (ipCounts[ip]) {
|
||||
|
|
Loading…
Reference in a new issue