summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README28
-rw-r--r--public/assets/css/css.css11
-rw-r--r--public/assets/js/nav.js2
-rw-r--r--public/index.html5
-rw-r--r--sample-env11
5 files changed, 40 insertions, 17 deletions
diff --git a/README b/README
index 0b618a9..2afd9f0 100644
--- a/README
+++ b/README
@@ -1,2 +1,26 @@
-luckyplop
-=========
+# plop
+
+Standalone drag-and-drop image upload website.
+
+## Installation
+
+Create a MySQL database and user for this project.
+
+`cp sample-env .env` and edit accordingly.
+
+Install all the modules and spin it up:
+
+```
+npm install
+./node_modules/.bin/knex migrate:latest
+pm2 start index.js --name plop
+```
+
+## Building the javascript
+
+```
+grunt
+```
+
+The app.min.js file should already be in git for convenience.
+
diff --git a/public/assets/css/css.css b/public/assets/css/css.css
index aa61167..b5cc410 100644
--- a/public/assets/css/css.css
+++ b/public/assets/css/css.css
@@ -6,15 +6,6 @@ body {
font-family: sans-serif;
line-height: 1;
}
-#luckyimage img {
- width: 100%;
- height: 100%;
- position: fixed;
- top: 0;
- left: 0;
- z-index: 1;
- display: block;
-}
#topnav {
height: 23px;
min-width: 500px;
@@ -50,7 +41,7 @@ a:visited {
color: blue;
}
-#luckyimage {
+#image {
position: fixed;
height: 100%;
width: 100%;
diff --git a/public/assets/js/nav.js b/public/assets/js/nav.js
index bfddc2c..c768b51 100644
--- a/public/assets/js/nav.js
+++ b/public/assets/js/nav.js
@@ -16,7 +16,7 @@ var NavView = View.extend({
this.id = -1
this.$pip = this.$("#pip")
this.$pip_img = this.$("#pip img")
- this.$image = this.$("#luckyimage")
+ this.$image = this.$("#image")
$(window).on("keydown", this.keydown.bind(this))
$(document).ajaxError(function(){
diff --git a/public/index.html b/public/index.html
index 47cb085..b02aae8 100644
--- a/public/index.html
+++ b/public/index.html
@@ -8,8 +8,7 @@
</head>
<body>
-<div id="luckyimage"></div>
-
+<div id="image"></div>
<div id="droparea"></div>
<div id="mobile_nav">
@@ -22,8 +21,6 @@
<div class="spinner"></div>
</body>
-
<script src='https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js'></script>
<script src='/p/assets/js/app.min.js'></script>
-
</html>
diff --git a/sample-env b/sample-env
new file mode 100644
index 0000000..cec1968
--- /dev/null
+++ b/sample-env
@@ -0,0 +1,11 @@
+DB_HOST=localhost
+DB_NAME=plop
+DB_USER=plop
+DB_PASS=
+HOST_NAME=lvh.me
+PORT=5000
+S3_KEY=
+S3_SECRET=
+S3_BUCKET=
+S3_DIR=/p/
+