Update deploy process to cope with new server

This commit is contained in:
Alexandre Bourlier 2018-05-06 08:17:07 +02:00
parent 1f148c416b
commit e6e7f29ee3
3 changed files with 7 additions and 9 deletions

View File

@ -3,8 +3,8 @@ export DN="http://app.happy-dev.fr"
export SDN="http://hd-ldp.happy-dev.fr"
php index.php > index.html
grunt
ssh happy-dev_alex@ssh-happy-dev.alwaysdata.net "rm -R hd-app; mkdir hd-app; cd hd-app; mkdir -p src/fonts; mkdir -p dist/css;"
scp index.html happy-dev_alex@ssh-happy-dev.alwaysdata.net:~/hd-app/
scp .htaccess happy-dev_alex@ssh-happy-dev.alwaysdata.net:~/hd-app/
scp -r dist/css/ happy-dev_alex@ssh-happy-dev.alwaysdata.net:~/hd-app/dist/
scp -r src/fonts/ happy-dev_alex@ssh-happy-dev.alwaysdata.net:~/hd-app/src/
ssh hd-app@ssh-hd-app.alwaysdata.net "rm -R hd-app; mkdir hd-app; cd hd-app; mkdir -p src/fonts; mkdir -p dist/css;"
scp index.html hd-app@ssh-hd-app.alwaysdata.net:~/hd-app/
scp .htaccess hd-app@ssh-hd-app.alwaysdata.net:~/hd-app/
scp -r dist/css/ hd-app@ssh-hd-app.alwaysdata.net:~/hd-app/dist/
scp -r src/fonts/ hd-app@ssh-hd-app.alwaysdata.net:~/hd-app/src/

View File

@ -43,13 +43,12 @@
data-bosh-service-url="https://conversejs.org/http-bind/"
data-debug="true"
data-jid="nomnom.im"
data-locales-url="http://hd-app.local/dist/lib/xmpp-chat-component/node_modules/converse.js/locale/{{{locale}}}/LC_MESSAGES/converse.json",
data-locales-url="<?php echo $cdn; ?>/node_modules/converse.js/locale/{{{locale}}}/LC_MESSAGES/converse.json",
data-room-jid="anonymous@conference.nomnom.im">
</hd-chat-window>
<script>
// Store url on load
var currentRoute = getCurrentRoute();
console.log(currentRoute);
var chatSingleton = document.querySelector("#chat-singleton");
var body = document.querySelector("body");
@ -74,7 +73,6 @@
if (currentRoute.indexOf("chat") == -1) {
currentRoute += "-chat";
}
console.log(currentRoute);
var currentView = document.querySelector("#" + currentRoute);
if (currentView.querySelector("hd-chat-window") == null) {
currentView.appendChild(chatSingleton);

View File

@ -12,4 +12,4 @@
<!-- Web components -->
<link rel="import" href="https://cdn.happy-dev.fr/ldp-display/ldp-display.html?v=<?php echo $v ?>" />
<link rel="import" href="https://cdn.happy-dev.fr/ldp-display/ldp-router.html?v=<?php echo $v ?>" />
<link rel="import" href="https://cdn.happy-dev.fr/xmpp-chat-component/chat-window-component.html?v=<?php echo $v ?>">
<link rel="import" href="https://xmpp-chat-component.happy-dev.fr/chat-window-component.html?v=<?php echo $v ?>">