How Do I Make Local A Node Programmatically Via Script Archive

How Do I Make Local A Node Programmatically Via Script Archive