Skip to content

Conversation

@barakeinav1
Copy link
Contributor

@barakeinav1 barakeinav1 commented Dec 3, 2025

@barakeinav1 barakeinav1 changed the title Barak/doc/testnet tee feat: testnet with tee support guide Dec 4, 2025
@netrome netrome changed the base branch from main to barak/doc/update_localnet_guide December 4, 2025 20:41
Base automatically changed from barak/doc/update_localnet_guide to main December 5, 2025 10:15
@barakeinav1 barakeinav1 force-pushed the barak/doc/testnet_tee branch 2 times, most recently from 3391ad2 to d772ef2 Compare December 10, 2025 06:44
@netrome
Copy link
Collaborator

netrome commented Dec 11, 2025

fixes https://github.com/near/mpc-private/issues/86

Fixing a private issue in a public PR feels a bit odd. It would be nice to have a dedicated public issue in this repo explaining that we have set up a cluster (we can still link to the private one about the setup), and that we should have a guide that helps anyone set up their own TEE testnet clusters.

Not a hard blocker though.

netrome
netrome previously approved these changes Dec 11, 2025
Copy link
Collaborator

@netrome netrome left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some questions and comments, but nothing blocking.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of creating a new file, we could reuse the existing docs/localnet/args/init.json template and just add an env var for the port.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are several differences between init.json and the nit_testnet_tee.json (different port ranges, IPs, and configurable account names).
I'm not saying it doesn't make sense to merge them together, but the overhead now (updating all localnet+localnet_TEE docs), is a but too much.

We can do this in a follow-up PR if really needed.


## Step 1: Create MPC Account

Since the faucet gives only **10 NEAR per account** (and the MPC contract storage costs **15 NEAR**),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't you run the faucet multiple times for the same account?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we sure there is no way to do this instead of the indirection? I'd advise to send a message to the SDK guys on telegram to ask for this. They are very responsive and helpful.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CC: @r-near

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you're using near-cli this is probably the simplest way to do it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@r-near I didn't understand your answer. is there a way to create an account with more than 10 near using faucet account? or fund it multiple time to achieve the same thing? if yes, can you provide the command (or link) ? I didn't find anything about this in documentation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we sure there is no way to do this instead of the indirection? I'd advise to send a message to the SDK guys on telegram to ask for this. They are very responsive and helpful.

do you mean this https://t.me/neardev ?

@DSharifi DSharifi changed the title feat: testnet with tee support guide docs: testnet with tee support guide Dec 11, 2025
Copy link
Contributor

@DSharifi DSharifi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

2 changes that are blocking:

  1. I think you updated libs/nearcore by mistake
  2. Don't hardcode barak_tee_test1_ as a prefix to the account names in your tests. I think we can reuse the approach for the current devnet README, where there are placeholders for the account name to use:
    First, create an MPC network. Pick a name; here I'll use
    "MPC_NETWORK_NAME=yourusername-test", but **ensure that your name is globally unique
    within the team**, so include your username in there.

MPC_ACCOUNT_ID=barak_tee_test1_sam.testnet
MPC_LOCAL_ADDRESS=127.0.0.1
MPC_SECRET_STORE_KEY=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
MPC_CONTRACT_ID=barak_tee_test1_mpc.testnet
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think the guide should have a hard coded testnet name with your firstname in it. Can we make the name more generic like we have in the other guides?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


## Step 1: Create MPC Account

Since the faucet gives only **10 NEAR per account** (and the MPC contract storage costs **15 NEAR**),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we sure there is no way to do this instead of the indirection? I'd advise to send a message to the SDK guys on telegram to ask for this. They are very responsive and helpful.

@barakeinav1
Copy link
Contributor Author

Fixing a private issue in a public PR feels a bit odd. It would be nice to have a dedicated public issue in this repo explaining that we have set up a cluster (we can still link to the private one about the setup), and that we should have a guide that helps anyone set up their own TEE testnet clusters.

sure:
I create an public task: #1660 and link to it.
and private task https://github.com/near/mpc-private/issues/86 is close by private PR https://github.com/near/mpc-private/pull/88

@barakeinav1
Copy link
Contributor Author

  1. I think you updated libs/nearcore by mistake

fixed

@barakeinav1
Copy link
Contributor Author

2. Don't hardcode barak_tee_test1_ as a prefix to the account names in your tests. I think we can reuse the approach for the current devnet README, where there are placeholders for the account name to use:

good idea

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create a guide for creating an MPC TEE cluster on testnet

5 participants