Compare commits
7 Commits
Author | SHA1 | Date |
---|---|---|
Matthias Kretschmann | d7b105feb6 | |
Matthias Kretschmann | ef8e5117fc | |
Matthias Kretschmann | dfdfa949ff | |
Matthias Kretschmann | ef6de3b2a6 | |
Matthias Kretschmann | e61f85b966 | |
Matthias Kretschmann | e172cfe289 | |
Matthias Kretschmann | eeebc60166 |
|
@ -1,13 +0,0 @@
|
|||
image: node:latest
|
||||
|
||||
cache:
|
||||
paths:
|
||||
- node_modules/
|
||||
|
||||
deploy:
|
||||
only:
|
||||
- master
|
||||
script:
|
||||
- npm install -g gulp
|
||||
- npm install
|
||||
- gulp deploy
|
18
README.md
18
README.md
|
@ -1,23 +1,12 @@
|
|||
# kretschmann.cat
|
||||
|
||||
> Highlighting Botero's cat sculpture in El Raval, Barcelona
|
||||
|
||||
[![build status](https://www.git.berlin/kremalicious/kretschmann.cat/badges/master/build.svg)](https://www.git.berlin/kremalicious/kretschmann.cat/commits/master)
|
||||
|
||||
<img src="site/assets/gato-del-raval.jpg" width="500" alt="gato del raval">
|
||||
> Highlighting Botero's cat sculpture in El Raval, Barcelona<br>
|
||||
> [https://kretschmann.cat](https://kretschmann.cat)
|
||||
|
||||
---
|
||||
|
||||
[https://kretschmann.cat](https://kretschmann.cat)
|
||||
|
||||
## Deployment
|
||||
|
||||
Just push to master and git.berlin CI will do the rest.
|
||||
|
||||
### Manual deployment
|
||||
|
||||
#### Prerequisite: Authentication
|
||||
|
||||
To deploy the site, you must authenticate yourself against the AWS API with your AWS credentials. Get your AWS access key and secret and add them to `~/.aws/credentials`:
|
||||
|
||||
```
|
||||
|
@ -29,12 +18,11 @@ aws_secret_access_key = <YOUR_SECRET_ACCESS_KEY>
|
|||
Continue with installing dependencies:
|
||||
|
||||
```bash
|
||||
npm install -g gulp
|
||||
npm install
|
||||
```
|
||||
|
||||
And finally deploy:
|
||||
|
||||
```bash
|
||||
gulp deploy
|
||||
npm run deploy
|
||||
```
|
||||
|
|
|
@ -20,22 +20,19 @@ gulp.task('deploy', function() {
|
|||
// create publisher, define config
|
||||
var publisher = awspublish.create({
|
||||
params: {
|
||||
'Bucket': S3BUCKET
|
||||
Bucket: S3BUCKET
|
||||
},
|
||||
'accessKeyId': process.env.AWS_ACCESS_KEY,
|
||||
'secretAccessKey': process.env.AWS_SECRET_KEY,
|
||||
'region': S3REGION
|
||||
region: S3REGION
|
||||
});
|
||||
|
||||
// define custom headers
|
||||
var headers = {
|
||||
'Cache-Control': 'max-age=315360000, no-transform, public'
|
||||
'Cache-Control': 'public,max-age=0,must-revalidate'
|
||||
};
|
||||
|
||||
return gulp.src(DIST + '**/*')
|
||||
.pipe(publisher.publish(headers))
|
||||
.pipe(publisher.sync()) // delete files in bucket that are not in local folder
|
||||
.pipe(publisher.cache())
|
||||
.pipe(awspublish.reporter({
|
||||
states: ['create', 'update', 'delete']
|
||||
}));
|
||||
|
|
File diff suppressed because it is too large
Load Diff
10
package.json
10
package.json
|
@ -7,12 +7,12 @@
|
|||
},
|
||||
"homepage": "https://kretschmann.cat",
|
||||
"main": "gulpfile.js",
|
||||
"devDependencies": {
|
||||
"gulp": ">=3.9.0",
|
||||
"gulp-awspublish": ">=3.0.0"
|
||||
"scripts": {
|
||||
"deploy": "gulp deploy"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=0.10.29"
|
||||
"devDependencies": {
|
||||
"gulp": "^4.0.2",
|
||||
"gulp-awspublish": ">=4.1.1"
|
||||
},
|
||||
"private": true,
|
||||
"repository": {
|
||||
|
|
|
@ -49,6 +49,15 @@ body {
|
|||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: #3a9085;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
body:before,
|
||||
body:after {
|
||||
content: "";
|
||||
|
@ -77,8 +86,20 @@ body:after {
|
|||
z-index: -1;
|
||||
}
|
||||
|
||||
article {
|
||||
article,
|
||||
footer {
|
||||
max-width: 35em;
|
||||
flex: 0 0 100%;
|
||||
}
|
||||
|
||||
footer {
|
||||
margin-top: 2rem;
|
||||
padding-bottom: 2rem;
|
||||
align-self: flex-end;
|
||||
}
|
||||
|
||||
small {
|
||||
font-size: .7rem;
|
||||
}
|
||||
|
||||
h1 {
|
||||
|
|
|
@ -21,5 +21,29 @@
|
|||
<p>Finalment, l'any 2003 es va decidir posar-lo definitivament al final de la jove Rambla del Raval.</p>
|
||||
</article>
|
||||
|
||||
<footer>
|
||||
<small>A project by <a href="https://matthiaskretschmann.com">matthias kretschmann</a></small>
|
||||
</footer>
|
||||
|
||||
<!-- Piwik -->
|
||||
<script type="text/javascript">
|
||||
var _paq = _paq || [];
|
||||
_paq.push(["setDomains", ["*.kretschmann.cat"]]);
|
||||
_paq.push(["setDoNotTrack", true]);
|
||||
_paq.push(['trackPageView']);
|
||||
_paq.push(['enableLinkTracking']);
|
||||
(function() {
|
||||
var u="//analytics.kremalicious.com/";
|
||||
_paq.push(['setTrackerUrl', u+'piwik.php']);
|
||||
_paq.push(['setSiteId', 4]);
|
||||
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
|
||||
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
|
||||
})();
|
||||
</script>
|
||||
<noscript><p><img src="//analytics.kremalicious.com/piwik.php?idsite=4" style="border:0;" alt="" /></p></noscript>
|
||||
<!-- End Piwik Code -->
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Reference in New Issue