Skip to content

Commit

Permalink
[Landing Page] Fix deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
brunolemos committed Aug 13, 2019
1 parent 7cdae87 commit d7c60cf
Show file tree
Hide file tree
Showing 12 changed files with 162 additions and 51 deletions.
6 changes: 1 addition & 5 deletions .nowignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,11 @@ packages/components/dist
packages/components/node_modules
packages/components/package.json
packages/components/src
packages/core
packages/desktop
packages/mobile
packages/web/build
packages/web/dist/**.map
packages/web/node_modules
packages/web/package.json
packages/web/src
patches
subdomains
tsconfig.json
tslint.json
subdomains
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ script:
-v ~/.cache/electron:/root/.cache/electron \
-v ~/.cache/electron-builder:/root/.cache/electron-builder \
electronuserland/builder:wine \
/bin/bash -c "yarn --pure-lockfile && yarn clean && yarn workspace @devhub/web build && yarn workspace @devhub/desktop build:skipweb --linux --win"
/bin/bash -c "yarn --pure-lockfile && yarn workspace @devhub/web build && yarn workspace @devhub/desktop build:skipweb --linux --win"
else
yarn --pure-lockfile && yarn clean && yarn workspace @devhub/web build && yarn workspace @devhub/desktop build:skipweb --mac && now --target production --token $NOW_TOKEN && now alias beta.devhubapp.com --token $NOW_TOKEN
yarn --pure-lockfile && yarn workspace @devhub/web build && yarn workspace @devhub/desktop build:skipweb --mac && yarn now --local-config ./now.app.json --target production --token $NOW_TOKEN && yarn now --local-config ./now.landing.json --target production --token $NOW_TOKEN
fi
before_cache:
Expand Down
1 change: 1 addition & 0 deletions next.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const withCSS = require('@zeit/next-css')

module.exports = withCSS({
target: 'serverless',
env: {
STRIPE_PUBLIC_KEY:
process.env.NODE_ENV === 'production'
Expand Down
28 changes: 28 additions & 0 deletions now.app.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"public": true,
"name": "devhub-app",
"alias": "app.devhubapp.com",
"version": 2,
"builds": [
{ "src": "packages/web/dist/**", "use": "@now/static" }
],
"routes": [
{
"src": "/(.*)\\.(.*)",
"dest": "/packages/web/dist/$1.$2"
},
{
"src": "/",
"dest": "/packages/web/dist/index.html"
},
{
"src": "/(.*)",
"status": 301, "headers": { "Location": "/" }
}
],
"regions": ["all"],
"github": {
"enabled": false,
"autoAlias": false
}
}
29 changes: 0 additions & 29 deletions now.json

This file was deleted.

14 changes: 14 additions & 0 deletions now.landing.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"public": true,
"name": "devhub-landing",
"alias": "devhubapp.com",
"version": 2,
"builds": [
{ "src": "next.config.js", "use": "@now/next" }
],
"regions": ["all"],
"github": {
"enabled": false,
"autoAlias": false
}
}
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"clean": "yarn workspaces run clean",
"dev": "yarn workspace @devhub/desktop compile && concurrently --kill-others \"yarn workspace @devhub/desktop compile -w\" \"yarn workspace @devhub/web start\" \"yarn workspace @devhub/mobile start\" \"wait-on http://localhost:3000 && yarn workspace @devhub/desktop start\"",
"dev:desktop": "cross-env BROWSER=none concurrently \"yarn dev:web\" \"yarn workspace @devhub/desktop compile -w\" \"wait-on http://localhost:3000 && yarn workspace @devhub/desktop start\"",
"dev:landing": "yarn workspace @devhub/core compile && concurrently \"yarn workspace @devhub/core compile -w\" \"PORT=4000 now dev\"",
"dev:landing": "yarn workspace @devhub/core compile && concurrently \"yarn workspace @devhub/core compile -w\" \"next\"",
"dev:mobile": "yarn workspace @devhub/mobile compile && concurrently --kill-others \"yarn workspace @devhub/mobile compile -w\" \"yarn workspace @devhub/mobile start\"",
"dev:web": "yarn workspace @devhub/web compile && concurrently --kill-others \"yarn workspace @devhub/web compile -w\" \"yarn workspace @devhub/web start\"",
"format": "yarn workspaces run format",
Expand All @@ -40,15 +40,15 @@
"dependencies": {
"@devhub/core": "0.93.0",
"@devhub/landing": "0.93.0",
"next": "9.0.2",
"next": "9.0.3",
"opencollective-postinstall": "2.0.2"
},
"devDependencies": {
"concurrently": "4.1.0",
"cross-env": "5.2.0",
"husky": "1.3.1",
"lint-staged": "8.1.5",
"now": "15.8.5",
"now": "16.1.1",
"patch-package": "6.0.5",
"postinstall-prepare": "1.0.1",
"prettier": "1.16.4",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ export default function UsedByCompaniesBlock(
</div>
</div>

<p className="text-xs text-muted-40 italic">
<p className="text-xs text-muted-60 italic">
Not affiliated with these companies. Used by some of their
individuals.
</p>
Expand Down
6 changes: 3 additions & 3 deletions packages/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
"build": "yarn compile && react-app-rewired build && shx rm -rf dist && mv build dist",
"clean": "shx rm -rf dist/*",
"compile": "tsc -b",
"deploy": "yarn build && cd ../../ && now --target production && cd -",
"deploy:beta": "yarn build && cd ../../ && now --target staging && now alias beta.devhubapp.com && cd -",
"deploy": "yarn build && cd ../../ && now --local-config ./now.app.json --target production && cd -",
"deploy:beta": "yarn build && cd ../../ && now --local-config ./now.app.json --target staging && now alias beta.devhubapp.com && cd -",
"eject": "react-app-rewired eject",
"format": "prettier --write '{.,src/**}/*.{js,jsx,ts,tsx}'",
"lint": "tslint -p .",
Expand All @@ -34,7 +34,7 @@
"@types/react": "16.8.24",
"@types/react-dom": "16.8.5",
"babel-plugin-react-native-web": "0.11.5",
"now": "15.8.5",
"now": "16.1.1",
"postinstall-prepare": "1.0.1",
"prettier": "1.16.4",
"react-app-rewired": "2.1.1",
Expand Down
2 changes: 1 addition & 1 deletion subdomains/slack/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@
"dependencies": {},
"devDependencies": {
"eslint": "5.9.0",
"now": "15.8.5"
"now": "16.1.1"
}
}
2 changes: 1 addition & 1 deletion subdomains/www/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@
"dependencies": {},
"devDependencies": {
"eslint": "5.9.0",
"now": "15.8.5"
"now": "16.1.1"
}
}
113 changes: 107 additions & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4299,9 +4299,9 @@ [email protected]:
safe-buffer "5.1.2"
vary "~1.1.2"

compression@^1.5.2, compression@^1.7.1:
compression@1.7.4, compression@^1.5.2, compression@^1.7.1:
version "1.7.4"
resolved "https://registry.yarnpkg.com/compression/-/compression-1.7.4.tgz#95523eff170ca57c29a0ca41e6fe131f41e5bb8f"
resolved "https://registry.npmjs.org/compression/-/compression-1.7.4.tgz#95523eff170ca57c29a0ca41e6fe131f41e5bb8f"
integrity sha512-jaSIDzP9pZVS4ZfQ+TzvtiWhdpFhE2RDHz8QJkpX9SIpLq88VueF5jJw6t+6CUQcAoA6t+x89MLrWAqpfDE8iQ==
dependencies:
accepts "~1.3.5"
Expand Down Expand Up @@ -10534,6 +10534,25 @@ [email protected]:
styled-jsx "3.2.1"
url "0.11.0"

[email protected]:
version "9.0.3"
resolved "https://registry.npmjs.org/next-server/-/next-server-9.0.3.tgz#b1372df158646ec40118c6e845d9a51764a21d89"
integrity sha512-fBTiph8k3GklHikeBcxkPZMTler7Q4oKSCUU7hJa0qDa8Sx+Tm4F1cn8FU0pM8C8Q1A+FVBZPEz5iJLJwhtZqA==
dependencies:
amp-toolbox-optimizer "1.2.0-alpha.1"
content-type "1.0.4"
cookie "0.4.0"
etag "1.8.1"
find-up "4.0.0"
fresh "0.5.2"
path-to-regexp "2.1.0"
prop-types "15.7.2"
raw-body "2.4.0"
react-is "16.8.6"
send "0.16.1"
styled-jsx "3.2.1"
url "0.11.0"

[email protected]:
version "9.0.2"
resolved "https://registry.npmjs.org/next/-/next-9.0.2.tgz#4de9da7ca64d89dd1759ad2b5d9d23a9dc3ca63b"
Expand Down Expand Up @@ -10586,6 +10605,59 @@ [email protected]:
webpack-sources "1.3.0"
worker-farm "1.7.0"

[email protected]:
version "9.0.3"
resolved "https://registry.npmjs.org/next/-/next-9.0.3.tgz#5c7b6f8dd142de907456a7c1df41e839ad16804a"
integrity sha512-Du0bGMdQDFq0itPm+OyaN/cKW20p9h6ZoEXnwIcop28L06pB45KcLEDdZgDZ75rk36UHiuwpRnjLMVzcbEqhRg==
dependencies:
"@babel/core" "7.4.5"
"@babel/plugin-proposal-class-properties" "7.4.4"
"@babel/plugin-proposal-object-rest-spread" "7.4.4"
"@babel/plugin-syntax-dynamic-import" "7.2.0"
"@babel/plugin-transform-modules-commonjs" "7.4.4"
"@babel/plugin-transform-runtime" "7.4.4"
"@babel/preset-env" "7.4.5"
"@babel/preset-react" "7.0.0"
"@babel/preset-typescript" "7.3.3"
"@babel/runtime" "7.4.5"
"@babel/runtime-corejs2" "7.4.5"
amphtml-validator "1.0.23"
async-sema "3.0.0"
autodll-webpack-plugin "0.4.2"
babel-core "7.0.0-bridge.0"
babel-loader "8.0.6"
babel-plugin-react-require "3.0.0"
babel-plugin-transform-async-to-promises "0.8.10"
babel-plugin-transform-react-remove-prop-types "0.4.24"
chalk "2.4.2"
compression "1.7.4"
find-up "4.0.0"
fork-ts-checker-webpack-plugin "1.3.4"
fresh "0.5.2"
launch-editor "2.2.1"
loader-utils "1.2.3"
mkdirp "0.5.1"
next-server "9.0.3"
prop-types "15.7.2"
prop-types-exact "1.2.0"
react-error-overlay "5.1.6"
react-is "16.8.6"
serialize-javascript "1.7.0"
source-map "0.6.1"
string-hash "1.1.3"
strip-ansi "5.2.0"
styled-jsx "3.2.1"
terser "4.0.0"
tty-aware-progress "1.0.4"
unfetch "4.1.0"
url "0.11.0"
watchpack "2.0.0-beta.5"
webpack "4.38.0"
webpack-dev-middleware "3.7.0"
webpack-hot-middleware "2.25.0"
webpack-sources "1.3.0"
worker-farm "1.7.0"

nice-try@^1.0.4:
version "1.0.5"
resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366"
Expand Down Expand Up @@ -10786,10 +10858,10 @@ normalize.css@^8.0.1:
resolved "https://registry.npmjs.org/normalize.css/-/normalize.css-8.0.1.tgz#9b98a208738b9cc2634caacbc42d131c97487bf3"
integrity sha512-qizSNPO93t1YUuUhP22btGOo3chcvDFqFaj2TRybP0DMxkHOCTYwp3n34fel4a31ORXy4m1Xq0Gyqpb5m33qIg==

now@15.8.5:
version "15.8.5"
resolved "https://registry.npmjs.org/now/-/now-15.8.5.tgz#1201ad17d8f21f41455e5aeaf879def711beb3c5"
integrity sha512-YjkbEzxANkqDrQG5FAMkK4asZnU5NYvVUCgeACZlASNs+SXZgDObDlIOW2OCs1TF5zBZStD9BMkE8l16imddQA==
now@16.1.1:
version "16.1.1"
resolved "https://registry.npmjs.org/now/-/now-16.1.1.tgz#692c406158c21bb0371de137b5f9957c861a4810"
integrity sha512-SXro0fOBTVBn+A2wEYV63It706egm7swgo6qb8zp6g07pOK0PQ1smeO0wmdYbx2Kuk5+Deh5t92KnZQi8wZjzA==

npm-bundled@^1.0.1:
version "1.0.6"
Expand Down Expand Up @@ -16018,6 +16090,35 @@ [email protected]:
watchpack "^1.5.0"
webpack-sources "^1.3.0"

[email protected]:
version "4.38.0"
resolved "https://registry.npmjs.org/webpack/-/webpack-4.38.0.tgz#6d77108404b08883c78f4e7e45a43c4e5c47c931"
integrity sha512-lbuFsVOq8PZY+1Ytz/mYOvYOo+d4IJ31hHk/7iyoeWtwN33V+5HYotSH+UIb9tq914ey0Hot7z6HugD+je3sWw==
dependencies:
"@webassemblyjs/ast" "1.8.5"
"@webassemblyjs/helper-module-context" "1.8.5"
"@webassemblyjs/wasm-edit" "1.8.5"
"@webassemblyjs/wasm-parser" "1.8.5"
acorn "^6.2.0"
ajv "^6.1.0"
ajv-keywords "^3.1.0"
chrome-trace-event "^1.0.0"
enhanced-resolve "^4.1.0"
eslint-scope "^4.0.0"
json-parse-better-errors "^1.0.2"
loader-runner "^2.3.0"
loader-utils "^1.1.0"
memory-fs "~0.4.1"
micromatch "^3.1.8"
mkdirp "~0.5.0"
neo-async "^2.5.0"
node-libs-browser "^2.0.0"
schema-utils "^1.0.0"
tapable "^1.1.0"
terser-webpack-plugin "^1.1.0"
watchpack "^1.5.0"
webpack-sources "^1.3.0"

websocket-driver@>=0.5.1:
version "0.7.0"
resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.0.tgz#0caf9d2d755d93aee049d4bdd0d3fe2cca2a24eb"
Expand Down

0 comments on commit d7c60cf

Please sign in to comment.