Document How to Run in Azure VM
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 35/100
- Issue-Typ
- Dokumentation
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Veraltet
- Tech-Stack
- azure, node.js, postgresql, shell, ubuntu
- Bereich
- cloud, databases, documentation, infrastructure
Rechercherichtung
Es wird keine Zieldokumentationsdatei genannt. Beginne damit, die vorhandene Deployment- oder Hosting-Dokumentation des Projekts zu finden, und vergleiche anschließend deren Konventionen mit den Azure VM-Schritten in diesem Issue. Als abgeschlossen gilt die Aufgabe, wenn ein wartbarer Leitfaden für Azure VM PostgreSQL, den Start von PostGraphile, den externen Zugriff, die Verifizierung und das Trennen des Prozesses abdeckt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Feature description
Document how to run in Azure on a VM.
Motivating example
I wanted to host in Azure and followed the steps below.
Steps that enabled me to host in an Azure VM:
Using Graphile over PostgreSQL 12
Created Ubuntu 20.04 Gen1 VM in Azure using static IP address
Connect using OSX Terminal SSH command
Launchpad
Terminal
ssh {vm_username}@{ip_address}
Create database user
sudo adduser {database_username}
Install PostgreSQL
sudo apt-get update
sudo apt-get install postgresql-12
CREATE ROLE {datebase_username} WITH LOGIN CREATEDB ENCRYPTED PASSWORD '{database_user_password}';
CREATE DATABASE {database_name};
GRANT ALL PRIVILEGES ON DATABASE {database_name} to {database_username};
\q
su {database_username}
psql -d {database_name}
CREATE TABLE testtable(
ID INT PRIMARY KEY NOT NULL,
NAME TEXT NOT NULL
);
\d
psql "postgres://{database_username}:{database_user_password}@localhost/{database_name}"
Note: connection strings require URL encoding.
Steps above were adapted from https://tecadmin.net/install-postgresql-server-on-ubuntu/
PostgreSQL Adding GUID (UUID) Support:
sudo su postgres
psql {database_name}
CREATE EXTENSION IF NOT EXISTS "uuid-ossp";
SELECT uuid_generate_v4();
Steps above were adapted from https://www.postgresqltutorial.com/postgresql-uuid/#:~:text=The%20Basics%20Of%20PostgreSQL%20UUID,table%20with%20UUID%20column.
Install NPM
sudo apt install npm
Install Yarn
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt update && sudo apt install yarn
Install PostGraphile
yarn add postgraphile
Install Optional Plugins
yarn add @graphile-contrib/pg-simplify-inflector
Start Graphile with:
npx postgraphile \
--subscriptions \
--watch \
--dynamic-json \
--no-setof-functions-contain-nulls \
--no-ignore-rbac \
--no-ignore-indexes \
--show-error-stack=json \
--extended-errors hint,detail,errcode \
--append-plugins @graphile-contrib/pg-simplify-inflector \
--export-schema-graphql schema.graphql \
--graphiql "/graphiql" \
--enhance-graphiql \
--allow-explain \
--enable-query-batching \
--legacy-relations omit \
--connection postgres://{database_username}:{database_user_password}@localhost/{database_name} \
--owner-connection postgres://postgres:{postgress_password}@localhost/{database_name} \
--schema public \
--host 0.0.0.0
Documentation: CLI Usage: https://www.graphile.org/postgraphile/usage-cli/
Note: By default only localhost works but the --host 0.0.0.0 argument enables access from outside the server.
Note: sudo tcpdump port 5000 can be used to debug network issues to determine if traffic is hitting the server.
Verify Server is Working:
curl http://{vm_ip_address}:5000/graphiql
Disconnect Graphile execution from SSH window:
# Press <ctrl+z>
bg
disown -h
- Vorherrschende Sprache
- SCSS
- Sterne
- 27
- Forks
- 124
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Kein Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus graphile/graphile.github.io
-
help wanted quick
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 38/100
graphile/graphile.github.io#401 · 1 Kommentar · 1 Reaktion ·
-
website: Update details on homepage and sponsor pageEvtl. wieder frei @jemgillam hat das vor 1119 Tagen übernommen, und es ist kein Pull Request offen. Offenquick
graphile/graphile.github.io#399 · 4 Kommentare · 1 zugewiesene Person ·
-
sponsor page: New wording around Grafast needed!Evtl. wieder frei @jemgillam hat das vor 1149 Tagen übernommen, und es ist kein Pull Request offen. Offen
graphile/graphile.github.io#393 · 1 Reaktion · 1 zugewiesene Person ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 38/100
graphile/graphile.github.io#341 · 1 Reaktion ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 25/100
graphile/graphile.github.io#280 · 2 Kommentare · 5 Reaktionen ·
Alle Issues in graphile/graphile.github.io
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 80/100
huggingface/huggingface_hub#5443 ·
Maintainer antworten meist innerhalb von 1 Tag
-
needs-triage
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 85/100
Azure/azure-sdk-for-python#50155 · 1 Reaktion ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 62/100
Maintainer antworten meist innerhalb von 1 Tag
-
EtcdCluster deletion never completes with the cert-manager provider when a Certificate is missingOffen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
etcd-io/etcd-operator#577 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 86/100