Skip to content

Commit

Permalink
Merge pull request #91 from 0xPolygonID/develop
Browse files Browse the repository at this point in the history
Devel to prod
  • Loading branch information
x1m3 authored Sep 16, 2024
2 parents 19efff3 + 4196046 commit c99d961
Show file tree
Hide file tree
Showing 9 changed files with 74 additions and 10 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/deploy_new_account.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@ env:
CAMINO_COLUMBUS_SENDER_DID: "did:polygonid:camino:columbus:3E1DZ5qrNCJctmUS3nphEkfsvqYs1kL5oGTtEpYiov"
CAMINO_COLUMBUS_NETWORK_FLAG: "0b10000011"
CAMINO_COLUMBUS_CHAIN_ID: "501"

LINEA_SEPOLIA_CONTRACT_ADDRESS: "0xD8869a439a07Edcc990F8f21E638702ee9273293"
LINEA_SEPOLIA_SENDER_DID: "did:iden3:linea:sepolia:28itzVLBHnMJV8sdjyffcAtWCx8HZ7btdKXxs7fJ6v"
LINEA_SEPOLIA_NETWORK_FLAG: "0b0100_1000"
LINEA_SEPOLIA_NODE_URL: "https://rpc.sepolia.linea.build"
LINEA_SEPOLIA_CHAIN_ID: "59141"
LINEA_SEPOLIA_METHOD: "iden3"

jobs:
build-backend:
Expand Down Expand Up @@ -89,6 +96,14 @@ jobs:
echo -e " chainID: ${{ env.CAMINO_COLUMBUS_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.CAMINO_COLUMBUS_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.CAMINO_COLUMBUS_SENDER_DID }}" >> resolvers_settings.yaml
echo -e "linea:" >> resolvers_settings.yaml
echo -e " sepolia:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.LINEA_SEPOLIA_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
echo -e " networkURL: ${{ env.LINEA_SEPOLIA_NODE_URL }}" >> resolvers_settings.yaml
echo -e " chainID: ${{ env.LINEA_SEPOLIA_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.LINEA_SEPOLIA_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.LINEA_SEPOLIA_SENDER_DID }}" >> resolvers_settings.yaml
echo -e " method: ${{ env.LINEA_SEPOLIA_METHOD }}" >> resolvers_settings.yaml
echo -e "privado:" >> resolvers_settings.yaml
echo -e " test:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.PRIVADO_TEST_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/dev_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@ env:
PRIVADO_TEST_SENDER_DID: "did:iden3:privado:test:2Sn9bnRFiTYNfbS1dVTaGCUXuMfnQMUcTCAXtFv4Gr"
PRIVADO_TEST_NETWORK_FLAG: "0b1010_0010"
PRIVADO_TEST_CHAIN_ID: "21001"

LINEA_SEPOLIA_CONTRACT_ADDRESS: "0xD8869a439a07Edcc990F8f21E638702ee9273293"
LINEA_SEPOLIA_SENDER_DID: "did:iden3:linea:sepolia:28itzVLBHnMJV8sdjyffcAtWCx8HZ7btdKXxs7fJ6v"
LINEA_SEPOLIA_NETWORK_FLAG: "0b0100_1000"
LINEA_SEPOLIA_NODE_URL: "https://rpc.sepolia.linea.build"
LINEA_SEPOLIA_CHAIN_ID: "59141"
LINEA_SEPOLIA_METHOD: "iden3"

jobs:
build-backend:
Expand Down Expand Up @@ -87,6 +94,14 @@ jobs:
echo -e " chainID: ${{ env.CAMINO_COLUMBUS_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.CAMINO_COLUMBUS_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.CAMINO_COLUMBUS_SENDER_DID }}" >> resolvers_settings.yaml
echo -e "linea:" >> resolvers_settings.yaml
echo -e " sepolia:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.LINEA_SEPOLIA_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
echo -e " networkURL: ${{ env.LINEA_SEPOLIA_NODE_URL }}" >> resolvers_settings.yaml
echo -e " chainID: ${{ env.LINEA_SEPOLIA_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.LINEA_SEPOLIA_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.LINEA_SEPOLIA_SENDER_DID }}" >> resolvers_settings.yaml
echo -e " method: ${{ env.LINEA_SEPOLIA_METHOD }}" >> resolvers_settings.yaml
echo -e "privado:" >> resolvers_settings.yaml
echo -e " test:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.PRIVADO_TEST_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/prod_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,13 @@ env:
PRIVADO_TEST_NETWORK_FLAG: "0b1010_0010"
PRIVADO_TEST_CHAIN_ID: "21001"

LINEA_SEPOLIA_CONTRACT_ADDRESS: "0xD8869a439a07Edcc990F8f21E638702ee9273293"
LINEA_SEPOLIA_SENDER_DID: "did:iden3:linea:sepolia:28itzVLBHnMJV8sdjyffcAtWCx8HZ7btdKXxs7fJ6v"
LINEA_SEPOLIA_NETWORK_FLAG: "0b0100_1000"
LINEA_SEPOLIA_NODE_URL: "https://rpc.sepolia.linea.build"
LINEA_SEPOLIA_CHAIN_ID: "59141"
LINEA_SEPOLIA_METHOD: "iden3"

jobs:
build-backend:
name: Build and push latest image to AWS
Expand Down Expand Up @@ -87,6 +94,14 @@ jobs:
echo -e " chainID: ${{ env.CAMINO_COLUMBUS_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.CAMINO_COLUMBUS_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.CAMINO_COLUMBUS_SENDER_DID }}" >> resolvers_settings.yaml
echo -e "linea:" >> resolvers_settings.yaml
echo -e " sepolia:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.LINEA_SEPOLIA_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
echo -e " networkURL: ${{ env.LINEA_SEPOLIA_NODE_URL }}" >> resolvers_settings.yaml
echo -e " chainID: ${{ env.LINEA_SEPOLIA_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.LINEA_SEPOLIA_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.LINEA_SEPOLIA_SENDER_DID }}" >> resolvers_settings.yaml
echo -e " method: ${{ env.LINEA_SEPOLIA_METHOD }}" >> resolvers_settings.yaml
echo -e "privado:" >> resolvers_settings.yaml
echo -e " test:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.PRIVADO_TEST_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/testing_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,13 @@ env:
PRIVADO_TEST_NETWORK_FLAG: "0b1010_0010"
PRIVADO_TEST_CHAIN_ID: "21001"

LINEA_SEPOLIA_CONTRACT_ADDRESS: "0xD8869a439a07Edcc990F8f21E638702ee9273293"
LINEA_SEPOLIA_SENDER_DID: "did:iden3:linea:sepolia:28itzVLBHnMJV8sdjyffcAtWCx8HZ7btdKXxs7fJ6v"
LINEA_SEPOLIA_NETWORK_FLAG: "0b0100_1000"
LINEA_SEPOLIA_NODE_URL: "https://rpc.sepolia.linea.build"
LINEA_SEPOLIA_CHAIN_ID: "59141"
LINEA_SEPOLIA_METHOD: "iden3"

jobs:
build-backend:
name: Build and push latest image to AWS
Expand Down Expand Up @@ -87,6 +94,14 @@ jobs:
echo -e " chainID: ${{ env.CAMINO_COLUMBUS_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.CAMINO_COLUMBUS_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.CAMINO_COLUMBUS_SENDER_DID }}" >> resolvers_settings.yaml
echo -e "linea:" >> resolvers_settings.yaml
echo -e " sepolia:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.LINEA_SEPOLIA_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
echo -e " networkURL: ${{ env.LINEA_SEPOLIA_NODE_URL }}" >> resolvers_settings.yaml
echo -e " chainID: ${{ env.LINEA_SEPOLIA_CHAIN_ID }}" >> resolvers_settings.yaml
echo -e " networkFlag: ${{ env.LINEA_SEPOLIA_NETWORK_FLAG }}" >> resolvers_settings.yaml
echo -e " did: ${{ env.LINEA_SEPOLIA_SENDER_DID }}" >> resolvers_settings.yaml
echo -e " method: ${{ env.LINEA_SEPOLIA_METHOD }}" >> resolvers_settings.yaml
echo -e "privado:" >> resolvers_settings.yaml
echo -e " test:" >> resolvers_settings.yaml
echo -e " contractAddress: ${{ env.PRIVADO_TEST_CONTRACT_ADDRESS }}" >> resolvers_settings.yaml
Expand Down
2 changes: 1 addition & 1 deletion api/api.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
openapi: 3.1.0
info:
title: Polygon ID
title: Privado ID
description: |
Documentation for the Backend Verifier API
version: "1"
Expand Down
Binary file removed api/polygon.png
Binary file not shown.
Binary file added api/privadoid.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 12 additions & 8 deletions api/spec.html
Original file line number Diff line number Diff line change
@@ -1,29 +1,33 @@
<!doctype html>
<html>
<head>
<title>Polygon ID - Verifier Backend</title>
<title>Privado ID - Verifier API</title>
<meta charset="utf-8">
<link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">
<script type="module" src="https://unpkg.com/rapidoc/dist/rapidoc-min.js"></script>
</head>
<body>
<rapi-doc
id = "the-doc"
id = "the-doc"
spec-url="/static/docs/api/api.yaml"
theme = "light"
regular-font = "Nunito"
primary-color = "#7F56D9"
primary-color = "#93f598"
allow-spec-url-load = false
allow-spec-file-load = false
show-header = false
render-style = "read"
show-method-in-nav-bar = "as-colored-text"
navigation-item-text = path
render-style = "focused"
layout = "row"
allow-authentication = true
sort-endpoints-by="summary"
>
<!-- <img slot="nav-logo" src="{logo}" style="width:50px; height:50px"/>-->
<img
slot="nav-logo"
src="https://docs.privado.id/img/privado_logo.svg"
width="100px"
height="100px"
/>
</rapi-doc>

<script>
window.addEventListener('DOMContentLoaded', () => {
const rapidocEl = document.getElementById('the-doc');
Expand Down
2 changes: 1 addition & 1 deletion internal/api/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ func documentation(w http.ResponseWriter, _ *http.Request) {
}

func favicon(w http.ResponseWriter, _ *http.Request) {
writeFile("api/polygon.png", "image/png", w)
writeFile("api/privadoid.png", "image/png", w)
}

func swagger(w http.ResponseWriter, _ *http.Request) {
Expand Down

0 comments on commit c99d961

Please # to comment.