Skip to content

Commit

Permalink
Add license + enhance README (#106)
Browse files Browse the repository at this point in the history
* Add license + readme

* Update README.md
  • Loading branch information
ielashi authored Jun 30, 2021
1 parent 6a04124 commit 468c268
Show file tree
Hide file tree
Showing 5 changed files with 137 additions and 69 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Use this with
#
# docker build -t dfinity_wallet .
# docker run --rm --entrypoint cat dfinity_wallet /nns_ui.wasm > nns_ui.wasm
# docker build -t nns-dapp .
# docker run --rm --entrypoint cat nns-dapp /nns_ui.wasm > nns_ui.wasm

FROM ubuntu:20.10

Expand Down
103 changes: 103 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
INTERNET COMPUTER COMMUNITY SOURCE LICENSE

v1.0

License text copyright © 2021 DFINITY Foundation, All Rights Reserved. “Internet
Computer Community Source License” is a trademark of the DFINITY Foundation.

TERMS AND CONDITIONS

If you use this code (the “software”), you accept this license. If you do not
accept the license, do not use the software.

1. Definitions

The terms “reproduce,” “reproduction,” “derivative works,” and distribution”
have the same meaning here as under U.S. copyright law.

A “contribution” is the original software, or any additions or changes to the
software.

A “contributor” is any person that distributes its contribution under this
license.

“Internet Computer” is the decentralized compute platform originated by the
DFINITY Foundation and stewarded by the Internet Computer Association.

2. Grant of Rights

(A) Copyright Grant - Subject to the terms of this license, including the
license conditions and limitations in Section 3, each contributor grants you a
non-exclusive, worldwide, royalty-free copyright license to reproduce its
contribution, prepare derivative works of its contribution, and distribute its
contribution or any derivative works that you create.

(B) Patent Grant - Subject to the terms of this license, including the license
conditions and limitations in Section 3, each contributor grants you a
non-exclusive, worldwide, royalty-free license under its licensed patents to
make, have made, use, sell, offer for sale, import, and/or otherwise dispose of
its contribution in the software or derivative works of the contribution in the
software.

3. Conditions and Limitations

(A) Platform Limitation - The licenses granted in sections 2(A) and 2(B) extend
only to the software or derivative works that you create that run directly on
the Internet Computer platform.

(B) This license does not grant you rights to use any contributors’ name, logo,
or trademarks.

(C) If you distribute any portion of the software, you must retain all
copyright, patent, trademark, and attribution notices that are present in the
software.

(D) If you distribute any portion of the software in source code form, you may
do so only under this license by including a complete copy of this license with
your distribution. If you distribute any portion of the software in compiled or
object code form, you may only do so under a license that complies with this
license.

(E) If you have modified the Software or created derivative works, and
distribute such modifications or derivative works, you will cause the modified
files to carry prominent notices so that recipients know that they are not
receiving the original software. Such notices must state: (i) that you have
changed the software; and (ii) the date of any changes.

(F) THE SOFTWARE COMES "AS IS", WITH NO WARRANTIES. THIS MEANS THE CONTRIBUTORS
GIVE NO EXPRESS, IMPLIED OR STATUTORY WARRANTY, INCLUDING WITHOUT LIMITATION,
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE OR ANY
WARRANTY OF TITLE OR NON-INFRINGEMENT. ALSO, YOU MUST PASS THIS DISCLAIMER ON
WHENEVER YOU DISTRIBUTE THE SOFTWARE OR DERIVATIVE WORKS.

(G) DFINITY WILL NOT BE LIABLE FOR ANY DAMAGES RELATED TO THE SOFTWARE OR THIS
LICENSE, INCLUDING DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL OR INCIDENTAL
DAMAGES, TO THE MAXIMUM EXTENT THE LAW PERMITS, NO MATTER WHAT LEGAL THEORY IT
IS BASED ON (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED
INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE
PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF YOU OR OTHER PARTY HAS BEEN
ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. ALSO, YOU MUST PASS THIS LIMITATION
OF LIABILITY ON WHENEVER YOU DISTRIBUTE THE SOFTWARE OR DERIVATIVE WORKS.

(H) If you bring a patent claim against any contributor over patents that you
claim are infringed by the software or a claim against anyone for their use of
the software, your license the software automatically terminates.

(I) Your rights under this license automatically terminates if you breach it in
any way.

(J) Each contributor grants to the Foundation the right to distribute the
contribution of the contributor under a license which is more permissive than
this license. A more permissive license shall be in particular a license with
less restrictions on how the contribution can be reproduced, modified and
distributed than this license. A more permissive license may be in particular
understood as a license that sets asides the platform limitation in section 3
(A) of this license. A more permissive license shall include in particular the
Apache License Version 2.0 (or future versions thereof) and the MIT License. The
decision on such a distribution under a more permissive license is at the sole
discretion of the Foundation

(K) The Foundation reserves all rights not expressly granted to you in this
license.

END OF TERMS AND CONDITIONS
75 changes: 32 additions & 43 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,50 @@
# Network Nervous System App
# Network Nervous System Dapp

Your one-stop shop for all needs NNS
The NNS Dapp is a dapp that provides a user friendly way to interact with the NNS of the Internet Computer. With it, you can:

## Getting Started
* Send/receive ICP
* Stake neurons
* Create canisters
* Top up canisters with cycles
* View and vote on NNS proposals

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
## Official build

### Prerequisites
The official build should ideally be reproducible, so that independent parties
can validate that we really deploy what we claim to deploy.

We try to achieve some level of reproducibility using a Dockerized build
environment. The following steps _should_ build the official Wasm image

docker build -t internet-identity-service .
docker run --rm --entrypoint cat nns-dapp /nns_ui.wasm > nns_ui.wasm
sha256sum nns_ui.wasm

The resulting `nns_ui.wasm` is ready for deployment as
`qoctq-giaaa-aaaaa-aaaea-cai`, which is the reserved principal for this service.

Our CI also performs these steps; you can compare the SHA256 with the output there, or download the artifact there.

### Software versions

What things you need to install the software and how to install them

1. [Flutter](https://flutter.dev/docs/get-started/install)
2. [Node/NPM](https://nodejs.org/en/) - Recommended `> 14.16.1`
3. [DFX](https://sdk.dfinity.org/docs/index.html) - Recommended `>= 0.7.0`
4. `didc` in your `$PATH`: Can be downloaded [here](https://github.com/dfinity/candid/releases).
- [Flutter](https://flutter.dev/docs/get-started/install) version `2.0.6`
- [Node/NPM](https://nodejs.org/en/) version `>= v14.17.0`
- [DFX](https://sdk.dfinity.org/docs/index.html) version `>= 0.7.0`
- `didc` in your `$PATH`: Can be downloaded [here](https://github.com/dfinity/candid/releases).

### Development

Development relies on the presence of a testnet that is setup with the II, governance, ledger, and cycle minting canisters.
Development relies on the presence of a testnet that is setup with the II, governance, ledger, and cycle minting canisters. We do not yet support fully local development.

We rely on the `xsmallh` testnet. To deploy there, run the following:
To deploy to the `xsmallh` testnet, run the following:

```shell
./deploy.sh xsmallh
```

Then run the following command to open the UI:
You can now access the frontend using:

```shell
open "https://$(dfx canister --no-wallet --network xsmallh id nns_ui).xsmallh.dfinity.network"
Expand All @@ -34,36 +53,6 @@ open "https://$(dfx canister --no-wallet --network xsmallh id nns_ui).xsmallh.df
To work on the UI locally, either use your IDE, or run the following:

```
cd dfinity_wallet
cd frontend/dart
flutter run --no-sound-null-safety --dart-define=DEPLOY_ENV=staging --web-port 5021
```

## TODO: Running the tests

Explain how to run the automated tests for this system

### Break down into end to end tests

Explain what these tests test and why

```
Give an example
```

## Deployment

This can be deployed to another network by passing the `--network` variable in the `dfx deploy` step.

```shell
dfx deploy --network=alpha
```

## Built With

- [DFX](https://sdk.dfinity.org/docs/index.html) - SDK and command line
- [TypeScript](https://www.typescriptlang.org/) - Front-end typings and compilation
- [Browserify](http://browserify.org/) - Used to generate RSS Feeds

## TODO: License

This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details
16 changes: 0 additions & 16 deletions frontend/dart/README.md

This file was deleted.

8 changes: 0 additions & 8 deletions frontend/dart/core/README.md

This file was deleted.

0 comments on commit 468c268

Please sign in to comment.