Skip to content

Commit

Permalink
Merge pull request #12 from ninech/static
Browse files Browse the repository at this point in the history
feat: add static apps
  • Loading branch information
ctrox authored Dec 19, 2023
2 parents 61be3fe + 12ad8d8 commit dfcaf14
Show file tree
Hide file tree
Showing 9 changed files with 27,986 additions and 0 deletions.
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,3 +62,23 @@ nctl create application django-example \
--env=DJANGO_SU_PASSWORD=<INSERT A PASSWORD HERE> \
--env=SECRET_KEY=<VERY LONG RANDOM SECRET KEY>
```

## Static

For static sites we have two examples:

* just a plain `index.html`

```bash
nctl create application static-html \
--git-url=https://github.com/ninech/deploio-examples \
--git-sub-path=static/html
```

* a frontend react app built with `npm`

```bash
nctl create application static-react \
--git-url=https://github.com/ninech/deploio-examples \
--git-sub-path=static/react
```
39 changes: 39 additions & 0 deletions static/html/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<!DOCTYPE html>

<html lang="en">

<head>
<meta charset="UTF-8" />
<title>Static Site on deplo.io</title>
<meta name="viewport" content="width=device-width,initial-scale=1" />
<meta name="description" content="" />
<meta name="theme-color" content="">

<style>
body {
background-color: #141d50;
color: #ffffff;
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI',
'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans',
'Droid Sans', 'Helvetica Neue', 'Segoe UI Emoji',
'Apple Color Emoji', 'Noto Color Emoji', sans-serif;
}
.logo {
filter: invert(1);
width: 30%;
display: block;
margin-left: auto;
margin-right: auto;
}
.title {
text-align: center;
}
</style>
</head>

<body>
<h1 class="title">Static Site</h1>
<img class="logo" src="https://docs.nine.ch/img/theme/deploio.svg"></img>
</body>

</html>
23 changes: 23 additions & 0 deletions static/react/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
Loading

0 comments on commit dfcaf14

Please sign in to comment.