-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #19 from STEM-C/feature/continuous-delivery
Feature/continuous delivery
- Loading branch information
Showing
29 changed files
with
1,506 additions
and
1,291 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Directories | ||
*/node_modules | ||
cms/.tmp | ||
|
||
# Data | ||
cms/er_diagram.png | ||
cms/strapi.sql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
FROM strapi/base | ||
|
||
WORKDIR /usr/src/app/client | ||
|
||
# Install client dependencies | ||
COPY ./client/package.json . | ||
COPY ./client/yarn.lock . | ||
RUN yarn install | ||
|
||
# Build client | ||
COPY ./client . | ||
RUN yarn build | ||
|
||
WORKDIR /usr/src/app | ||
|
||
# Install app dependencies | ||
COPY ./cms/package.json . | ||
COPY ./cms/yarn.lock . | ||
RUN yarn install | ||
|
||
# Bundle app source | ||
COPY ./cms . | ||
RUN mv ./client/build/* ./public && rm -r ./client | ||
|
||
# Set the env to prod for build | ||
ENV NODE_ENV production | ||
|
||
# Build admin | ||
RUN yarn build | ||
|
||
# Port mapping | ||
EXPOSE 1337 | ||
|
||
# Run when the container is started | ||
CMD yarn start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"name": "STEM-C", | ||
"description": "Web Blockly IDE for Arduino", | ||
"repository": "https://github.com/STEM-C/STEM-C", | ||
"addons": [ | ||
{ | ||
"plan": "heroku-postgresql", | ||
"as": "DATABASE" | ||
} | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,5 +31,6 @@ | |
"last 1 firefox version", | ||
"last 1 safari version" | ||
] | ||
} | ||
}, | ||
"homepage": "." | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"cms": "", | ||
"compile": "https://stem-c-compile.herokuapp.com" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"cms": "", | ||
"compile": "https://stem-c-compile.herokuapp.com" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import development from './config/development.json' | ||
import staging from './config/staging.json' | ||
import production from './config/production.json' | ||
|
||
const getHosts = () => { | ||
const { hostname } = window.location | ||
|
||
if (hostname.includes('localhost')) return development | ||
if (hostname.includes('staging')) return staging | ||
return production | ||
} | ||
|
||
export const cms = getHosts().cms | ||
export const compile = getHosts().compile |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.