# Possible to SSH into gateway machine and import tags via a python script?

**URL:** <https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132>\
**Category:** Ignition\
**Created:** [September 28, 2020, 6:14pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132 "2020-09-28T18:14:21Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 28, 2020, 6:14pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/1 "2020-09-28T18:14:21Z")

</div>

Hi! I’d like to set up a script a gateway machine that can update tags from a git repository. I know there is a Python API available to update tags. I guess my real question is, is that API available outside the gateway event scripts and the project scripts? is it possible to write a python script saved on the gateway machine, ssh in, execute it and have tags updated in this manner?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [September 28, 2020, 6:21pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/2 "2020-09-28T18:21:00Z")

</div>

No, not really. Ignition’s Python (Jython, it should be clarified) environment is only available within the context of the running Ignition instance.  
There are a lot of different approaches to do what you’re ultimately describing, but one of the easiest might be to use the Web Dev module. You can create your own web API (responding to GET/POST/PATCH/etc requests) that call arbitrary Python code _within Ignition_, using passed parameters. It’s not as interactive as an SSH session, but it gets you remote access and Ignition script functions all in one.

---

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 28, 2020, 6:40pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/3 "2020-09-28T18:40:26Z")

</div>

Thanks I’ll look into this WebDev module!

---

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 29, 2020, 4:12pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/4 "2020-09-29T16:12:26Z")

</div>

Does this WebDev module operate specifically with a project? The documentation suggests I access the WebDev modules from the Designer with an open project. I was looking for a way to access the API outside of any specific project.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [September 29, 2020, 4:17pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/5 "2020-09-29T16:17:12Z")

</div>

> [@srieger](#):
>
> I was looking for a way to access the API outside of any specific project.

Scripts running within a gateway project context have full access to all non-project resources and APIs in the gateway. (Though module SDK API usage is not officially supported.)

---

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 29, 2020, 4:18pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/6 "2020-09-29T16:18:44Z")

</div>

I understand. So if I’ll just have to manage this from within one specific project but I could use it to say, import tags via the API

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [September 29, 2020, 4:58pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/7 "2020-09-29T16:58:05Z")

</div>

> [@srieger](#):
>
> import tags via the API

Yes.

---

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 29, 2020, 5:15pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/8 "2020-09-29T17:15:54Z")

</div>

Is this module available in trial mode? I can’t find it anywhere.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [September 29, 2020, 5:40pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/9 "2020-09-29T17:40:42Z")

</div>

Have you specifically installed the module? It should show up as a node in the project tree in the designer.

---

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 29, 2020, 5:46pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/10 "2020-09-29T17:46:40Z")

</div>

No, the documentation didn’t mention, installation that I saw. Where can I download the module?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [September 29, 2020, 6:42pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/11 "2020-09-29T18:42:01Z")

</div>

[https://inductiveautomation.com/downloads/ignition/8.0.16](https://inductiveautomation.com/downloads/ignition/8.0.16)  
Download the ‘WebDev’ module for your version.

---

<div class="post-metadata">

**Author:** ![srieger](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@srieger](https://forum.inductiveautomation.com/u/srieger)\
**Post date:** [September 29, 2020, 6:52pm UTC](https://forum.inductiveautomation.com/t/possible-to-ssh-into-gateway-machine-and-import-tags-via-a-python-script/39132/12 "2020-09-29T18:52:39Z")

</div>

Ahh, I totally missed that. Much appreciated!
