Skip to content

Commit 2452940

Browse files
Update README.md
1 parent 94f45b9 commit 2452940

File tree

1 file changed

+2
-71
lines changed

1 file changed

+2
-71
lines changed

README.md

+2-71
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
55
- [**Create your database**](#create-your-database)
66
- [Deploy to **Glitch**](#deploy-to-glitch)
7-
- [Deploy to **Azure**](#deploy-to-azure)
87
- [Deploy to **Heroku**](#deploy-to-heroku)
98

109
## Create your database
@@ -44,75 +43,7 @@ Not tested 100%. Same as with Heroku, will sleep after a while.
4443
5. Wait for it to setup
4544
6. Press **Share**-button to get your URL to live site. It should be something for example like: `https://seemly-truthful-scribe.glitch.me/`. And your DB will be at `https://seemly-truthful-scribe.glitch.me/posts`
4645

47-
## Deploy to **Azure**
48-
49-
<img align="right" width="100px" height="auto" src="https://docs.microsoft.com/en-us/azure/media/index/azure-germany.svg" alt="Azure">
50-
51-
You can also use _Microsoft Azure_ to deploy a smaller app for free to the Azure platform. The service is not as easy as _Heroku_ and you might go insane because the documentation is really really bad at some times and it's hard to troubleshoot.
52-
53-
The **pros** are that on _Azure_ the app **will not be forced to sleep**. It will sleep automatically on inactivity but you can just visit it and it will start up.
54-
55-
## Installation
56-
57-
1 . Create a Microsoft Account that you can use on Azure: </br>
58-
https://azure.microsoft.com/
59-
60-
2 . Install the `azure-cli`: <br/>
61-
https://docs.microsoft.com/en-us/cli/azure/install-azure-cli
62-
_This might cause some trouble, you will see. Remember to restart your terminal or maybe your computer if the commands after this does not work_
63-
64-
3 . Login to the service via the command line and follow the instructions: </br>
65-
66-
```bash
67-
az login
68-
```
69-
70-
_You will be prompted to visit a website and paste a confirmation code_
71-
72-
## Create the project
73-
74-
1 . [Create your database](#create-your-database)
75-
76-
2 . Create a resource group for your projects, replace the name to whatever you want just be sure to use the same group name in all commands to come. You only have to create the resource group and service plan once, then you can use the same group and plan for all other apps you create if you like.
77-
78-
```bash
79-
az group create -n NameOfResourceGroup -l northeurope
80-
```
81-
82-
3 . Create a service plan:
83-
84-
```
85-
az appservice plan create -n NameOfServicePlan -g NameOfResourceGroup
86-
```
87-
88-
4 . Create the actual app and supply the service plan and resource group
89-
90-
```bash
91-
az webapp create -n NameOfApp -g NameOfResourceGroup --plan NameOfServicePlan
92-
```
93-
94-
5 . Create deployment details. A git-repo is not created automatically so we have to create it with a command:
95-
96-
```bash
97-
az webapp deployment source config-local-git -n NameOfApp -g NameOfResourceGroup
98-
```
99-
100-
6 . From the command in step 5 you should get a **url** in return. Copy this url and add it as a remote to your local git project, for example:
101-
102-
```bash
103-
git remote add azure https://[email protected]/deploy-testing.git
104-
```
105-
106-
7 . Now you should be able to push your app:
107-
108-
```bash
109-
git push azure master
110-
```
111-
112-
You should be prompted to supply a password, this should be the pass to your account. If not, you can choose a different password at your Dashboard for Azure: **[https://portal.azure.com/](https://portal.azure.com/)**
113-
114-
Choose **App Services** in the sidebar to the left and the choose your app in the list that appears then go to **Deployment Credentials** to change your password for deployment:<br>
115-
https://docs.microsoft.com/en-us/azure/app-service/app-service-deployment-credentials
46+
---
11647

11748
## Deploy to **Heroku**
11849

@@ -187,6 +118,7 @@ You also have to make changes to the port, you can't hardcode a dev-port. But yo
187118
```js
188119
const port = process.env.PORT || 4000;
189120
```
121+
---
190122

191123
### Author Links
192124

@@ -200,4 +132,3 @@ const port = process.env.PORT || 4000;
200132
- [LinkedIn](https://www.linkedin.com/in/ikramdeveloper/)
201133
- [StackOverflow](https://stackoverflow.com/users/13859212/ikram-ul-haq)
202134

203-
---

0 commit comments

Comments
 (0)