Skip to content

Instantly share code, notes, and snippets.

@maggit
Created January 27, 2015 18:56
Show Gist options
  • Save maggit/209aee3ebfd3d16e1a69 to your computer and use it in GitHub Desktop.
Save maggit/209aee3ebfd3d16e1a69 to your computer and use it in GitHub Desktop.

#Deploy de un sitio web estático en heroku

Supongamos que tienes un archivo index.html con contenido estatico. Renombralo a home.html.

Crea index.php y agrega la siguiente linea:

<?php include_once("home.html"); ?>

Sí no has creado tu proyecto en heroku, este es el momento de hacerlo:

heroku create

Haz commit de tu código a heroku:

git add .
git commit -m 'Agregando mi sito estatico.'
git push heroku master

Deberías de ver algo como lo siguiente:

-----> Heroku receiving push
-----> PHP app detected
-----> Bundling Apache version 2.2.22
-----> Bundling PHP version 5.3.10
-----> Discovering process types
Default types for PHP -> web
-----> Compiled slug size: 9.5MB
-----> Launching... done, v4

Felicidades! Haz publicado un sitio estatico en heroku con una linea de código :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment