You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wanted to make easily the process of deploying code to server on each push to repository. I tried almost all suggested ways to do it but they didn't work. So I created this package. It supports Ubuntu servers and Bitbucket (GitHub and GitLab support in progress!) repos.
10
+
I wanted to make easily the process of deploying code to server on each push to repository. I tried almost all suggested ways to do it but they didn't work. So I created this package. It supports Ubuntu servers and GitHub/GitLab/Bitbucket repos.
11
11
12
12
## Uses
13
13
14
-
Nodeployed uses [Fastify](https://www.fastify.io) as Node.js Server, [Execa](https://github.com/sindresorhus/execa) to run such commands to deploy code and [Minimist](https://github.com/substack/minimist) to parse command arguments.
14
+
Nodeployed uses [Fastify](https://www.fastify.io) as Node.js server, [Execa](https://github.com/sindresorhus/execa) to run such commands to deploy code and [Minimist](https://github.com/substack/minimist) to parse command arguments.
15
15
16
16
## Server preparation
17
17
18
18
To be able to use it sucessfully, you need:
19
19
20
20
- Install Node.js and npm on your server
21
21
22
+
* Setup your Apache/NGINX server to _reverse proxy_ all requests to `http://localhost:YOUR_PORT` in `location` block:
22
23
23
-
- Setup your Apache/NGINX server to _reverse proxy_ all requests to `http://localhost:YOUR_PORT` in `location` block:
24
-
25
-
- For NGINX change your server block config to something like this:
24
+
* For `NGINX` change your server block config to something like this:
26
25
27
26
```nginx
28
27
# Your server in /etc/nginx/sites-available/example.com
29
28
server {
30
29
...
31
-
location / {
30
+
location /deploy/ {
32
31
proxy_pass http://localhost:YOUR_PORT;
33
32
proxy_http_version 1.1;
34
33
proxy_set_header Upgrade $http_upgrade;
@@ -40,11 +39,11 @@ server {
40
39
}
41
40
```
42
41
43
-
- For Apache2:
42
+
- For `Apache2`:
44
43
45
44
```apache
46
45
<VirtualHost *:*>
47
-
ProxyPass / http://0.0.0.0:3000/
46
+
ProxyPass /deploy/ http://0.0.0.0:3000/
48
47
ServerName localhost
49
48
</VirtualHost>
50
49
```
@@ -55,19 +54,108 @@ server {
55
54
56
55
## Usage
57
56
58
-
Install package globally from `NPM repo` via `npm`or `yarn`and start the process with [pm2](http://pm2.keymetrics.io/):
57
+
Install package globally from `NPM repo` via `npm` and start the process with [pm2](http://pm2.keymetrics.io/):
0 commit comments