Skip to content

Commit

Permalink
Update description and theme
Browse files Browse the repository at this point in the history
  • Loading branch information
leijiankun committed Jan 29, 2018
1 parent c6f979f commit 5c47996
Show file tree
Hide file tree
Showing 4 changed files with 76 additions and 70 deletions.
23 changes: 12 additions & 11 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,23 @@
version: '2'
version: '3'
services:
mysql:
image: mysql
hostname: mysql
environment:
- MYSQL_USER=root
- MYSQL_DATABASE=spring_blog
- MYSQL_DATABASE=spring_blog_prod
- MYSQL_ROOT_PASSWORD=123456
webapp:
image: java:8
links:
- mysql:mysql
# - redis:redis
depends_on:
- mysql
- redis
volumes:
- ./build/libs/SpringBlog-0.1.jar:/app/app.jar
- ./application-prod.yml:/app/application-prod.yml
- ./build/libs/SpringBlog-0.0.1-SNAPSHOT.jar:/app/app.jar
ports:
- "9000:9000"
command: "java -jar /app/app.jar --spring.profiles.active=dev"
- "9000:8080"
# command: "java -jar /app/app.jar --spring.profiles.active=prod --spring.config.location=/app/application-prod.yml"
command: "java -jar /app/app.jar --spring.profiles.active=prod"

# redis:
# image: redis
redis:
image: redis
10 changes: 5 additions & 5 deletions src/main/resources/application-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,20 @@ spring:
caching: true

jpa:
show-sql: false
show-sql: true

datasource:
driver-class-name: com.mysql.jdbc.Driver
url: jdbc:mysql://127.0.0.1/spring_blog_prod?useUnicode=true&characterEncoding=utf8&useSSL=false
url: jdbc:mysql://mysql/spring_blog_prod?useUnicode=true&characterEncoding=utf8&useSSL=false
username: root
password:
password: 123456

redis:
host: localhost
host: redis
port: 6379
default_expire_time: 86400

logging:
level:
org.springframework.web: ERROR
com.raysmond.blog: INFO
com.raysmond.blog: DEBUG
5 changes: 4 additions & 1 deletion src/main/resources/templates/home/index.jade
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@ block page_title
h1 #{App.getSiteName()}
p.meta #{App.getSiteSlogan()}

p Hi, there. I'm Raysmond, a postgraduate of Computer Science in Fudan University from Shanghai, China. I love developing software and web applications and I blog about them.
p
| SpringBlog is a very simple and clean-design blog system implemented with Spring Boot. You can find the sourcecode
| of the project at <a href="https://github.com/Raysmond/SpringBlog">Github</a>.
| <br/>I hope you find it helpful.

block title
= App.getSiteName()
Expand Down
108 changes: 55 additions & 53 deletions src/main/webapp/css/theme-light.css
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
html{
html {
font-size: 100%;
}

body {
background: #fff;
font: 300 1em/1.8 "Helvetica Neue",Helvetica, Microsoft Yahei, Hiragino Sans GB, Microsoft Sans Serif, WenQuanYi Micro Hei, sans;
/*font: 300 1em/1.8 "Helvetica Neue", Helvetica, Microsoft Yahei, Hiragino Sans GB, Microsoft Sans Serif, WenQuanYi Micro Hei, sans;*/
font: 300 1em/1.8 -apple-system,SF UI Text,Arial,PingFang SC,Hiragino Sans GB,Microsoft YaHei,WenQuanYi Micro Hei,sans-serif;;
-webkit-font-smoothing: antialiased;
color: #515862;
}

a{
a {
-webkit-transition-property: opacity;
-moz-transition-property: opacity;
-o-transition-property: opacity;
Expand All @@ -21,24 +22,26 @@ a{
}

/* override typo css */
h1, h2, h3, h4, h5, h6{
h1, h2, h3, h4, h5, h6 {
color: #47596D;
-webkit-font-smoothing: normal;
}
.typo a{

.typo a {
color: #337ab7;
}
.typo a:hover{

.typo a:hover {
color: #666;
}

hr{
hr {
border-color: #eee;
}

/* end */

pre{
pre {
background: #F9F9F9;
border-radius: 3px;
border-color: #eee;
Expand All @@ -49,66 +52,66 @@ pre{
word-wrap: normal;
}

a.btn-default{
a.btn-default {
color: #888;
}

a.btn-default:hover{
a.btn-default:hover {
background: #fff;
color: #333;
border-color: #333;
}

.navbar{
.navbar {
z-index: 100;
}

.navbar a.navbar-brand{
.navbar a.navbar-brand {
color: #9caab0;
font-weight: bold;
}

.navbar .container{
.navbar .container {
border-bottom: 1px #eee solid;
padding-top: 10px;
}

.navbar li a{
.navbar li a {
color: #9caab0;
text-transform: uppercase;
font-weight: bold;
font-size: 0.9em;
}

.nav>li>a:focus, .nav>li>a:hover{
.nav > li > a:focus, .nav > li > a:hover {
background: none;
color: #888;
}

@media screen and (max-width: 480px) {
#navbar{
#navbar {
text-align: center;
}
.nav>li{

.nav > li {
display: inline-block;
}
}

.container{
.container {
padding-top: 20px;
max-width: 840px;
}

.main-container{
.main-container {
padding-top: 0;
}

form input, form button{
form input, form button {
margin-top: 10px;
}


.header-title{
.header-title {
padding: 0 100px;
width: 100%;
position: relative;
Expand All @@ -118,24 +121,25 @@ form input, form button{
margin-top: 20px;
}

.header-title p{
.header-title p {
font-size: 0.9em;

}
.header-title p.meta{

.header-title p.meta {
color: #999;
font-size: 0.9em;
}

.header-title .avatar img{
.header-title .avatar img {
margin-top: 20px;
border-radius: 50%;
box-shadow: 0 0 0 3px #fff, 0 0 0 4px #ccc;
width: 80px;
height: 80px;
}

.header-title-wrapper{
.header-title-wrapper {
display: table-cell;
vertical-align: middle;
margin: 0 auto;
Expand All @@ -144,132 +148,130 @@ form input, form button{
display: block;
}


.post{
.post {
padding: 50px 80px;
margin-bottom: 30px;
}

@media screen and (max-width: 480px) {
.post{
.post {
padding: 30px 10px;
}
.post h2.title, .post .meta{

.post h2.title, .post .meta {
text-align: center;
}
}


.post .meta, .typo .post .meta{
color: rgba(187,187,187,0.8);
.post .meta, .typo .post .meta {
color: rgba(187, 187, 187, 0.8);
font-size: 0.9em;
}

.post h1 > a, .post h2 > a, .post h3 > a, .post h4 > a{
.post h1 > a, .post h2 > a, .post h3 > a, .post h4 > a {
color: #75889E;
text-decoration: none;
}

.post h2.title{
.post h2.title {
margin-bottom: 20px;
margin-top: 15px;
}


.post h2.title a:hover, .post h2.title a:focus{
.post h2.title a:hover, .post h2.title a:focus {
color: #888;
}

.post .info{
.post .info {
margin-top: 30px;
text-align: center;
color: #888;
font-size: 0.9em;
}

.post .comments{
.post .comments {
margin-top: 30px;
padding-top: 30px;
border-top: 1px #eee solid;
}

.post ul.tags{
.post ul.tags {
margin-left: 0;
padding-left: 0;
}

.post ul.tags li{
.post ul.tags li {
display: inline-block;
list-style: none;
margin-left: 10px;
}

.latest-posts{
.latest-posts {
width: 80%;
margin: 0 auto;
margin-top: 30px;
margin-bottom: 50px;
}

.loadmore{
.loadmore {
text-align: center;
margin-top: 40px;
}

.post-item{
.post-item {
text-align: center;
width: 80%;
margin: 10px auto;
padding: 10px 20px;
}

.post-item:hover{
.post-item:hover {
background: #F2F8FB;
}

.post-item a > h2{
.post-item a > h2 {
font-size: 1.1em;
margin-top: 0;
color: #515862;
font-weight: 400;
}

.post-item .meta{
.post-item .meta {
text-align: center;
color: #888;
font-size: 0.9em;
}

ul.archive-list li span.month{
ul.archive-list li span.month {
width: 60px;
display: inline-block;
}

ul.tags li{
ul.tags li {
margin: 5px 10px;
}

.footer{
.footer {
text-align: center;
margin-bottom: 50px;
font-size: 0.9em;
color: #888;
}

.footer a{
.footer a {
color: #888;
}

.footer p, .typo .footer p {
margin-bottom: 0.4em;
}

.footer-wrapper{
.footer-wrapper {
display: block;
max-width: 500px;
margin: 0 auto;
}

.footer-wrapper hr{
.footer-wrapper hr {
border-color: #ddd;
}

0 comments on commit 5c47996

Please sign in to comment.