Skip to content
This repository has been archived by the owner on Jul 29, 2024. It is now read-only.

Commit

Permalink
Add metadata tags
Browse files Browse the repository at this point in the history
  • Loading branch information
v1v committed Apr 21, 2022
1 parent af4f37a commit fae3c71
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions ogc/provision.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,11 @@ def create(self, layout, env, **kwargs) -> db.Node:
layout["tags"].append(f"user-{user.slug}")
tags["created"] = now
tags["user_tag"] = f"user-{user.slug}"
# Store some extra metadata similar to what other projects use
epoch = datetime.datetime.now().timestamp()
tags["created_date"] = epoch
tags["environment"] = "ogc"
tags["repo"] = "ogc"

node = self._create_node(**opts)
self.provisioner.ex_create_tags(self.node(instance_id=node.instance_id), tags)
Expand Down

0 comments on commit fae3c71

Please sign in to comment.